[tor-commits] [tor-browser/tor-browser-52.2.0esr-7.5-1] Bug 21830: Copying large test from web console leaks to /tmp

gk at torproject.org gk at torproject.org
Fri Aug 4 05:59:40 UTC 2017


commit 06580161f901dedf60e6dcb9252e7ce6b3e7b37b
Author: Georg Koppen <gk at torproject.org>
Date:   Fri Aug 4 05:55:49 2017 +0000

    Bug 21830: Copying large test from web console leaks to /tmp
    
    Patch written by Neill Miller
---
 widget/nsTransferable.cpp | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/widget/nsTransferable.cpp b/widget/nsTransferable.cpp
index e99d45401df8..976180c7581e 100644
--- a/widget/nsTransferable.cpp
+++ b/widget/nsTransferable.cpp
@@ -39,6 +39,7 @@ Notes to self:
 #include "nsIFile.h"
 #include "nsILoadContext.h"
 #include "mozilla/UniquePtr.h"
+#include "mozilla/Preferences.h"
 
 NS_IMPL_ISUPPORTS(nsTransferable, nsITransferable)
 
@@ -248,6 +249,11 @@ nsTransferable::Init(nsILoadContext* aContext)
 
   if (aContext) {
     mPrivateData = aContext->UsePrivateBrowsing();
+  } else {
+    // without aContext here to provide PrivateBrowsing information,
+    // we defer to the active configured setting
+    mPrivateData =
+      mozilla::Preferences::GetBool("browser.privatebrowsing.autostart");
   }
 #ifdef DEBUG
   mInitialized = true;



More information about the tor-commits mailing list