delete vs. delete[] vs. free fixes.
Thanks to "Bruce Mitchener, Jr." <bruce@cybersight.com for finding all these and making patches. git-svn-id: svn://10.0.0.236/trunk@25592 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -821,7 +821,7 @@ nsNetlibService::SetProxyHTTP(nsString& aProxyHTTP) {
|
||||
return NS_FALSE;
|
||||
csPort = nsSPort.ToNewCString();
|
||||
if (!csPort) {
|
||||
delete proxy;
|
||||
delete[] proxy;
|
||||
return NS_FALSE;
|
||||
}
|
||||
|
||||
@@ -833,8 +833,8 @@ nsNetlibService::SetProxyHTTP(nsString& aProxyHTTP) {
|
||||
if ( PREF_OK != PREF_SetIntPref(pref_proxyHttpPort, port) ) {
|
||||
rv = NS_FALSE;
|
||||
}
|
||||
delete proxy;
|
||||
delete csPort;
|
||||
delete[] proxy;
|
||||
delete[] csPort;
|
||||
|
||||
NET_SelectProxyStyle(PROXY_STYLE_MANUAL);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user