b=128508 "freeze nsIChannel nsIRequest" r=gagan, sr=rpotts, a=asa

git-svn-id: svn://10.0.0.236/trunk@117002 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
darin%netscape.com
2002-03-20 22:50:33 +00:00
parent 8763a125c1
commit 8defbf5d26
171 changed files with 1894 additions and 1635 deletions

View File

@@ -637,7 +637,6 @@ nsScriptLoader::OnStreamComplete(nsIStreamLoader* aLoader,
if (stringLen) {
nsAutoString characterSet, preferred;
nsCOMPtr<nsIUnicodeDecoder> unicodeDecoder;
nsCOMPtr<nsIHttpChannel> httpChannel;
nsCOMPtr<nsIChannel> channel;
nsCOMPtr<nsIRequest> req;
@@ -646,14 +645,12 @@ nsScriptLoader::OnStreamComplete(nsIStreamLoader* aLoader,
if (NS_FAILED(rv)) return rv;
channel = do_QueryInterface(req);
httpChannel = do_QueryInterface(channel);
if (httpChannel) {
nsXPIDLCString charsetheader;
rv = httpChannel->GetCharset(getter_Copies(charsetheader));
if (channel) {
nsCAutoString charsetVal;
rv = channel->GetContentCharset(charsetVal);
if (NS_SUCCEEDED(rv)) {
characterSet = NS_ConvertASCIItoUCS2(charsetheader);
characterSet = NS_ConvertASCIItoUCS2(charsetVal);
nsCOMPtr<nsICharsetAlias> calias(do_GetService(kCharsetAliasCID,&rv));
if(NS_SUCCEEDED(rv) && calias) {