Bug 1063197 - Callsites of NS_NewInputStreamChannel in /toolit/ (r=mak77)
authorChristoph Kerschbaumer <mozilla@christophkerschbaumer.com>
Thu, 16 Oct 2014 11:17:22 -0700
changeset 210812 9eeedb28b328098a331eaf49101c87f6bef74d5b
parent 210811 3de863f08848a5dce83576e01ddc323005d4d17a
child 210813 a5208bb3c5dad3801636de4d0e2468e87c8f6af0
push id1
push userroot
push dateMon, 20 Oct 2014 17:29:22 +0000
reviewersmak77
bugs1063197
milestone36.0a1
Bug 1063197 - Callsites of NS_NewInputStreamChannel in /toolit/ (r=mak77)
toolkit/components/places/nsAnnoProtocolHandler.cpp
--- a/toolkit/components/places/nsAnnoProtocolHandler.cpp
+++ b/toolkit/components/places/nsAnnoProtocolHandler.cpp
@@ -330,18 +330,22 @@ nsAnnoProtocolHandler::NewFaviconChannel
                            getter_AddRefs(outputStream),
                            MAX_FAVICON_SIZE, MAX_FAVICON_SIZE, true,
                            true);
   NS_ENSURE_SUCCESS(rv, GetDefaultIcon(_channel));
 
   // Create our channel.  We'll call SetContentType with the right type when
   // we know what it actually is.
   nsCOMPtr<nsIChannel> channel;
-  rv = NS_NewInputStreamChannel(getter_AddRefs(channel), aURI, inputStream,
-                                EmptyCString());
+  rv = NS_NewInputStreamChannel(getter_AddRefs(channel),
+                                aURI,
+                                inputStream,
+                                nsContentUtils::GetSystemPrincipal(),
+                                nsILoadInfo::SEC_NORMAL,
+                                nsIContentPolicy::TYPE_OTHER);
   NS_ENSURE_SUCCESS(rv, GetDefaultIcon(_channel));
 
   // Now we go ahead and get our data asynchronously for the favicon.
   nsCOMPtr<mozIStorageStatementCallback> callback =
     new faviconAsyncLoader(channel, outputStream);
   NS_ENSURE_TRUE(callback, GetDefaultIcon(_channel));
   nsFaviconService* faviconService = nsFaviconService::GetFaviconService();
   NS_ENSURE_TRUE(faviconService, GetDefaultIcon(_channel));