what i do is :
"Foo() { nsString toto; toto.Assign(....); ..... //free(toto) -> crashes //nsMemory::free(toto) -> crashes
Yeah... variables allocated on the stack don't need to be freed. If you want to destroy toto before calling Foo again, try this:
void Foo() {
{
nsString toto;
toto.Assign(...);
// ...
}
Foo();
}However, unless your compiler eliminates tail recursion, you will still run out of memory eventually (depending how deep your recursion is...)
i have too much non released variables.
Note that they would be released once you return from the function. _______________________________________________ mozilla-embedding mailing list [EMAIL PROTECTED] http://mail.mozilla.org/listinfo/mozilla-embedding
