mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-29 15:52:07 +00:00
fix for #79371; crash or app failure when Proxy type = PAC, sr=darin; r=gagan; a=asa
This commit is contained in:
parent
4e3f209b90
commit
d377ead1ee
@ -408,7 +408,21 @@ nsProtocolProxyService::ExamineForProxy(nsIURI *aURI, char * *aProxyHost, PRInt3
|
||||
aProxyHost,
|
||||
aProxyPort,
|
||||
aProxyType);
|
||||
|
||||
if (NS_SUCCEEDED(rv)) {
|
||||
if (*aProxyType == nsnull || !PL_strcasecmp("direct", *aProxyType)) {
|
||||
if (*aProxyHost) {
|
||||
nsMemory::Free(*aProxyHost);
|
||||
*aProxyHost = nsnull;
|
||||
}
|
||||
if (*aProxyType) {
|
||||
nsMemory::Free(*aProxyType);
|
||||
*aProxyType = nsnull;
|
||||
}
|
||||
*aProxyPort = -1;
|
||||
} else if (*aProxyPort <= 0) {
|
||||
*aProxyPort = -1;
|
||||
}
|
||||
}
|
||||
return rv;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user