And don't forget to free up the used memory.
This commit is contained in:
@@ -10,6 +10,7 @@ namespace std {
|
||||
|
||||
class ostringstream : public ostrstream {
|
||||
public:
|
||||
~ostringstream() { delete ostrstream::str(); }
|
||||
std::string str() { return string(ostrstream::str()) + '\0'; }
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user