Use delete[] for strings allocated with ToNewCString().
git-svn-id: svn://10.0.0.236/trunk@25546 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -1676,7 +1676,7 @@ NS_BASE int fputs(const nsString2& aString, FILE* out)
|
||||
if(len>0)
|
||||
::fwrite(cp, 1, len, out);
|
||||
if (cp != buf) {
|
||||
delete cp;
|
||||
delete[] cp;
|
||||
}
|
||||
return (int) len;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user