lists.torproject.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

tbb-commits

Thread Start a new thread
Threads by month
  • ----- 2026 -----
  • March
  • February
  • January
  • ----- 2025 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2021 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2020 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2019 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2018 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2017 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2016 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2015 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2014 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
tbb-commits@lists.torproject.org

  • 1 participants
  • 20078 discussions
[tor-browser/esr24] Bug 1024765 - Part 1: Add test-case for timers firing when the target thread is not running. r=bwc, a=sledru
by mikeperry@torproject.org 29 Aug '14

29 Aug '14
commit 74160028fb42bf8b86ec5b90c4fd2538f6cd2ac8 Author: Byron Campen [:bwc] <docfaraday(a)gmail.com> Date: Tue Jun 17 13:37:04 2014 -0700 Bug 1024765 - Part 1: Add test-case for timers firing when the target thread is not running. r=bwc, a=sledru --- xpcom/tests/TestTimers.cpp | 36 +++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git a/xpcom/tests/TestTimers.cpp b/xpcom/tests/TestTimers.cpp index 8b4ac25..545a8c4 100644 --- a/xpcom/tests/TestTimers.cpp +++ b/xpcom/tests/TestTimers.cpp @@ -14,6 +14,7 @@ #include "nsThreadUtils.h" #include "prinrval.h" #include "prmon.h" +#include "prthread.h" #include "mozilla/Attributes.h" #include "mozilla/ReentrantMonitor.h" @@ -78,6 +79,7 @@ public: : mThreadPtr(aThreadPtr), mReentrantMonitor(aReentrantMonitor) { } NS_IMETHOD Notify(nsITimer* aTimer) { + NS_ASSERTION(mThreadPtr, "Callback was not supposed to be called!"); nsCOMPtr<nsIThread> current(do_GetCurrentThread()); ReentrantMonitorAutoEnter mon(*mReentrantMonitor); @@ -133,13 +135,45 @@ TestTargetedTimers() return NS_OK; } +nsresult +TestTimerWithStoppedTarget() +{ + AutoTestThread testThread; + NS_ENSURE_TRUE(testThread, NS_ERROR_OUT_OF_MEMORY); + + nsresult rv; + nsCOMPtr<nsITimer> timer = do_CreateInstance(NS_TIMER_CONTRACTID, &rv); + NS_ENSURE_SUCCESS(rv, rv); + + nsIEventTarget* target = static_cast<nsIEventTarget*>(testThread); + + rv = timer->SetTarget(target); + NS_ENSURE_SUCCESS(rv, rv); + + // If this is called, we'll assert + nsCOMPtr<nsITimerCallback> callback = + new TimerCallback(nullptr, nullptr); + NS_ENSURE_TRUE(callback, NS_ERROR_OUT_OF_MEMORY); + + rv = timer->InitWithCallback(callback, PR_MillisecondsToInterval(100), + nsITimer::TYPE_ONE_SHOT); + NS_ENSURE_SUCCESS(rv, rv); + + testThread->Shutdown(); + + PR_Sleep(400); + + return NS_OK; +} + int main(int argc, char** argv) { ScopedXPCOM xpcom("TestTimers"); NS_ENSURE_FALSE(xpcom.failed(), 1); static TestFuncPtr testsToRun[] = { - TestTargetedTimers + TestTargetedTimers, + TestTimerWithStoppedTarget }; static uint32_t testCount = sizeof(testsToRun) / sizeof(testsToRun[0]);
1 0
0 0
[tor-browser/esr24] Bug 1024765 - Part 2: Make refcounting logic around PostTimerEvent more explicit. r=bz, a=sledru
by mikeperry@torproject.org 29 Aug '14

29 Aug '14
commit 24b9acce7908ed422611abb09b77ae5ae222ce0a Author: Byron Campen [:bwc] <docfaraday(a)gmail.com> Date: Mon Jun 16 14:13:04 2014 -0700 Bug 1024765 - Part 2: Make refcounting logic around PostTimerEvent more explicit. r=bz, a=sledru --- xpcom/threads/TimerThread.cpp | 17 +++++++---- xpcom/threads/nsTimerImpl.cpp | 67 +++++++++++++++++++++++++++-------------- xpcom/threads/nsTimerImpl.h | 4 ++- 3 files changed, 59 insertions(+), 29 deletions(-) diff --git a/xpcom/threads/TimerThread.cpp b/xpcom/threads/TimerThread.cpp index f8a7cb7..ebf5751 100644 --- a/xpcom/threads/TimerThread.cpp +++ b/xpcom/threads/TimerThread.cpp @@ -211,8 +211,9 @@ NS_IMETHODIMP TimerThread::Run() // must be racing with us, blocked in gThread->RemoveTimer waiting // for TimerThread::mMonitor, under nsTimerImpl::Release. - NS_ADDREF(timer); + nsRefPtr<nsTimerImpl> timerRef(timer); RemoveTimerInternal(timer); + timer = nullptr; { // We release mMonitor around the Fire call to avoid deadlock. @@ -222,16 +223,21 @@ NS_IMETHODIMP TimerThread::Run() if (PR_LOG_TEST(GetTimerLog(), PR_LOG_DEBUG)) { PR_LOG(GetTimerLog(), PR_LOG_DEBUG, ("Timer thread woke up %fms from when it was supposed to\n", - fabs((now - timer->mTimeout).ToMilliseconds()))); + fabs((now - timerRef->mTimeout).ToMilliseconds()))); } #endif // We are going to let the call to PostTimerEvent here handle the // release of the timer so that we don't end up releasing the timer // on the TimerThread instead of on the thread it targets. - if (NS_FAILED(timer->PostTimerEvent())) { - nsrefcnt rc; - NS_RELEASE2(timer, rc); + timerRef = nsTimerImpl::PostTimerEvent(timerRef.forget()); + + if (timerRef) { + // We got our reference back due to an error. + // Unhook the nsRefPtr, and release manually so we can get the + // refcount. + nsrefcnt rc = timerRef.forget().get()->Release(); + (void)rc; // The nsITimer interface requires that its users keep a reference // to the timers they use while those timers are initialized but @@ -246,7 +252,6 @@ NS_IMETHODIMP TimerThread::Run() // preventing this situation from occurring. MOZ_ASSERT(rc != 0, "destroyed timer off its target thread!"); } - timer = nullptr; } if (mShutdown) diff --git a/xpcom/threads/nsTimerImpl.cpp b/xpcom/threads/nsTimerImpl.cpp index fd4b391..717f280 100644 --- a/xpcom/threads/nsTimerImpl.cpp +++ b/xpcom/threads/nsTimerImpl.cpp @@ -105,9 +105,10 @@ class nsTimerEvent : public nsRunnable { public: NS_IMETHOD Run(); - nsTimerEvent(nsTimerImpl *timer, int32_t generation) - : mTimer(dont_AddRef(timer)), mGeneration(generation) { - // timer is already addref'd for us + nsTimerEvent() + : mTimer() + , mGeneration(0) + { MOZ_COUNT_CTOR(nsTimerEvent); MOZ_ASSERT(gThread->IsOnTimerThread(), @@ -132,8 +133,18 @@ public: DeleteAllocatorIfNeeded(); } + already_AddRefed<nsTimerImpl> ForgetTimer() + { + return mTimer.forget(); + } + + void SetTimer(already_AddRefed<nsTimerImpl> aTimer) + { + mTimer = aTimer; + mGeneration = mTimer->GetGeneration(); + } + private: - nsTimerEvent(); // Not implemented ~nsTimerEvent() { MOZ_COUNT_DTOR(nsTimerEvent); @@ -629,23 +640,27 @@ NS_IMETHODIMP nsTimerEvent::Run() return NS_OK; } -nsresult nsTimerImpl::PostTimerEvent() +already_AddRefed<nsTimerImpl> nsTimerImpl::PostTimerEvent(already_AddRefed<nsTimerImpl> aTimerRef) { - if (!mEventTarget) { + nsRefPtr<nsTimerImpl> timer(aTimerRef); + if (!timer->mEventTarget) { NS_ERROR("Attempt to post timer event to NULL event target"); - return NS_ERROR_NOT_INITIALIZED; + return timer.forget(); } // XXX we may want to reuse this nsTimerEvent in the case of repeating timers. - // Since TimerThread addref'd 'this' for us, we don't need to addref here. - // We will release in destroyMyEvent. We need to copy the generation number - // from this timer into the event, so we can avoid firing a timer that was - // re-initialized after being canceled. + // Since TimerThread addref'd 'timer' for us, we don't need to addref here. + // We will release either in ~nsTimerEvent(), or pass the reference back to + // the caller. We need to copy the generation number from this timer into the + // event, so we can avoid firing a timer that was re-initialized after being + // canceled. - nsRefPtr<nsTimerEvent> event = new nsTimerEvent(this, mGeneration); + // Note: We override operator new for this class, and the override is + // fallible! + nsRefPtr<nsTimerEvent> event = new nsTimerEvent; if (!event) - return NS_ERROR_OUT_OF_MEMORY; + return timer.forget(); #ifdef DEBUG_TIMERS if (PR_LOG_TEST(GetTimerLog(), PR_LOG_DEBUG)) { @@ -655,21 +670,29 @@ nsresult nsTimerImpl::PostTimerEvent() // If this is a repeating precise timer, we need to calculate the time for // the next timer to fire before we make the callback. - if (IsRepeatingPrecisely()) { - SetDelayInternal(mDelay); + if (timer->IsRepeatingPrecisely()) { + timer->SetDelayInternal(timer->mDelay); // But only re-arm REPEATING_PRECISE timers. - if (gThread && mType == TYPE_REPEATING_PRECISE) { - nsresult rv = gThread->AddTimer(this); + if (gThread && timer->mType == TYPE_REPEATING_PRECISE) { + nsresult rv = gThread->AddTimer(timer); if (NS_FAILED(rv)) - return rv; + return timer.forget(); } } - nsresult rv = mEventTarget->Dispatch(event, NS_DISPATCH_NORMAL); - if (NS_FAILED(rv) && gThread) - gThread->RemoveTimer(this); - return rv; + nsIEventTarget* target = timer->mEventTarget; + event->SetTimer(timer.forget()); + + nsresult rv = target->Dispatch(event, NS_DISPATCH_NORMAL); + if (NS_FAILED(rv)) { + timer = event->ForgetTimer(); + if (gThread) + gThread->RemoveTimer(timer); + } + return timer.forget(); + + return nullptr; } void nsTimerImpl::SetDelayInternal(uint32_t aDelay) diff --git a/xpcom/threads/nsTimerImpl.h b/xpcom/threads/nsTimerImpl.h index c318cf1..4a24060 100644 --- a/xpcom/threads/nsTimerImpl.h +++ b/xpcom/threads/nsTimerImpl.h @@ -54,7 +54,9 @@ public: friend struct TimerAdditionComparator; void Fire(); - nsresult PostTimerEvent(); + // If a failure is encountered, the reference is returned to the caller + static already_AddRefed<nsTimerImpl> PostTimerEvent( + already_AddRefed<nsTimerImpl> aTimerRef); void SetDelayInternal(uint32_t aDelay); NS_DECL_ISUPPORTS
1 0
0 0
[tor-browser/esr24] Bug 1023121 - Update our progress in docloader before calling state change listeners. r=smaug, a=sledru
by mikeperry@torproject.org 29 Aug '14

29 Aug '14
commit 36053c97fc9dcec827646d2660c5d5b18a35bdbe Author: Boris Zbarsky <bzbarsky(a)mit.edu> Date: Tue Jun 24 23:36:39 2014 -0400 Bug 1023121 - Update our progress in docloader before calling state change listeners. r=smaug, a=sledru --- uriloader/base/nsDocLoader.cpp | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/uriloader/base/nsDocLoader.cpp b/uriloader/base/nsDocLoader.cpp index de08daf..d08bc97 100644 --- a/uriloader/base/nsDocLoader.cpp +++ b/uriloader/base/nsDocLoader.cpp @@ -1016,16 +1016,20 @@ int64_t nsDocLoader::GetMaxTotalProgress() NS_IMETHODIMP nsDocLoader::OnProgress(nsIRequest *aRequest, nsISupports* ctxt, uint64_t aProgress, uint64_t aProgressMax) { - nsRequestInfo *info; int64_t progressDelta = 0; // // Update the RequestInfo entry with the new progress data // - info = GetRequestInfo(aRequest); - if (info) { + if (nsRequestInfo* info = GetRequestInfo(aRequest)) { + // Update info->mCurrentProgress before we call FireOnStateChange, + // since that can make the "info" pointer invalid. + int64_t oldCurrentProgress = info->mCurrentProgress; + progressDelta = int64_t(aProgress) - oldCurrentProgress; + info->mCurrentProgress = int64_t(aProgress); + // suppress sending STATE_TRANSFERRING if this is upload progress (see bug 240053) - if (!info->mUploading && (int64_t(0) == info->mCurrentProgress) && (int64_t(0) == info->mMaxProgress)) { + if (!info->mUploading && (int64_t(0) == oldCurrentProgress) && (int64_t(0) == info->mMaxProgress)) { // // If we receive an OnProgress event from a toplevel channel that the URI Loader // has not yet targeted, then we must suppress the event. This is necessary to @@ -1072,11 +1076,8 @@ NS_IMETHODIMP nsDocLoader::OnProgress(nsIRequest *aRequest, nsISupports* ctxt, FireOnStateChange(this, aRequest, flags, NS_OK); } - // Update the current progress count... - progressDelta = int64_t(aProgress) - info->mCurrentProgress; + // Update our overall current progress count. mCurrentSelfProgress += progressDelta; - - info->mCurrentProgress = int64_t(aProgress); } // // The request is not part of the load group, so ignore its progress
1 0
0 0
[tor-browser/esr24] Bug 1018414 - Skip test_error_codes.js on OS X. r=smaug, a=test-only
by mikeperry@torproject.org 29 Aug '14

29 Aug '14
commit 18a6858f8fe3af20919acdbfe97e40412d4d88e3 Author: Nathan Froyd <froydnj(a)mozilla.com> Date: Mon Jun 2 15:27:16 2014 -0400 Bug 1018414 - Skip test_error_codes.js on OS X. r=smaug, a=test-only --- content/base/test/unit/xpcshell.ini | 2 ++ 1 file changed, 2 insertions(+) diff --git a/content/base/test/unit/xpcshell.ini b/content/base/test/unit/xpcshell.ini index 9d7c35d..f1ef2e6 100644 --- a/content/base/test/unit/xpcshell.ini +++ b/content/base/test/unit/xpcshell.ini @@ -8,6 +8,8 @@ tail = [test_csputils.js] [test_cspreports.js] [test_error_codes.js] +# Bug 1018414: hardcoded localhost doesn't work properly on some OS X installs +skip-if = os == 'mac' [test_thirdpartyutil.js] [test_xhr_standalone.js] [test_xmlserializer.js]
1 0
0 0
[tor-browser/esr24] Automated checkin: version bump for firefox 24.6.0esr release. DONTBUILD CLOSED TREE a=release
by mikeperry@torproject.org 29 Aug '14

29 Aug '14
commit ebca3c103e7fe9416845f724879684bbcbd962c4 Author: ffxbld <none@none> Date: Mon Jun 9 21:01:00 2014 -0400 Automated checkin: version bump for firefox 24.6.0esr release. DONTBUILD CLOSED TREE a=release --- config/milestone.txt | 2 +- js/src/config/milestone.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/config/milestone.txt b/config/milestone.txt index 71e3ef9..c9dc647 100644 --- a/config/milestone.txt +++ b/config/milestone.txt @@ -10,4 +10,4 @@ # hardcoded milestones in the tree from these two files. #-------------------------------------------------------- -24.6.0 +24.6.0esrpre diff --git a/js/src/config/milestone.txt b/js/src/config/milestone.txt index 71e3ef9..c9dc647 100644 --- a/js/src/config/milestone.txt +++ b/js/src/config/milestone.txt @@ -10,4 +10,4 @@ # hardcoded milestones in the tree from these two files. #-------------------------------------------------------- -24.6.0 +24.6.0esrpre
1 0
0 0
[tor-browser/esr24] Bug 1018400 - Disable safebrowsing during reftests. r=ted, a=test-only
by mikeperry@torproject.org 29 Aug '14

29 Aug '14
commit 1891f376f6ae966d86818b891ef8b6bc250600f5 Author: Nathan Froyd <froydnj(a)mozilla.com> Date: Fri May 30 16:21:47 2014 -0400 Bug 1018400 - Disable safebrowsing during reftests. r=ted, a=test-only --- js/src/tests/user.js | 2 ++ layout/tools/reftest/runreftest.py | 3 +++ 2 files changed, 5 insertions(+) diff --git a/js/src/tests/user.js b/js/src/tests/user.js index 8849221..694d4d0 100755 --- a/js/src/tests/user.js +++ b/js/src/tests/user.js @@ -27,3 +27,5 @@ user_pref("javascript.options.werror", false); user_pref("toolkit.startup.max_resumed_crashes", -1); user_pref("security.turn_off_all_security_so_that_viruses_can_take_over_this_computer", true); user_pref("toolkit.telemetry.enabled", false); +user_pref("browser.safebrowsing.enabled", false); +user_pref("browser.safebrowsing.malware.enabled", false); diff --git a/layout/tools/reftest/runreftest.py b/layout/tools/reftest/runreftest.py index 683b0a1..2bb3d11 100644 --- a/layout/tools/reftest/runreftest.py +++ b/layout/tools/reftest/runreftest.py @@ -74,6 +74,9 @@ class RefTest(object): # Ensure that telemetry is disabled, so we don't connect to the telemetry # server in the middle of the tests. prefsFile.write('user_pref("toolkit.telemetry.enabled", false);\n') + # Likewise for safebrowsing. + prefsFile.write('user_pref("browser.safebrowsing.enabled", false);\n') + prefsFile.write('user_pref("browser.safebrowsing.malware.enabled", false);\n') for v in options.extraPrefs: thispref = v.split("=")
1 0
0 0
[tor-browser/esr24] No bug, Automated blocklist update from host bld-linux64-spot-050 - a=blocklist-update
by mikeperry@torproject.org 29 Aug '14

29 Aug '14
commit 44c7993368742ecc5b3c33c157f5fbc2490dda86 Author: ffxbld <none@none> Date: Sat Jun 14 03:08:31 2014 -0700 No bug, Automated blocklist update from host bld-linux64-spot-050 - a=blocklist-update --- browser/app/blocklist.xml | 76 ++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 71 insertions(+), 5 deletions(-) diff --git a/browser/app/blocklist.xml b/browser/app/blocklist.xml index 2039450..91763d3 100644 --- a/browser/app/blocklist.xml +++ b/browser/app/blocklist.xml @@ -1,5 +1,5 @@ <?xml version="1.0"?> -<blocklist xmlns="http://www.mozilla.org/2006/addons-blocklist" lastupdate="1400782040000"> +<blocklist xmlns="http://www.mozilla.org/2006/addons-blocklist" lastupdate="1402612020000"> <emItems> <emItem blockID="i454" id="sqlmoz(a)facebook.com"> <versionRange minVersion="0" maxVersion="*" severity="3"> @@ -274,6 +274,12 @@ <prefs> </prefs> </emItem> + <emItem blockID="i596" id="{b99c8534-7800-48fa-bd71-519a46cdc7e1}"> + <versionRange minVersion="0" maxVersion="*" severity="1"> + </versionRange> + <prefs> + </prefs> + </emItem> <emItem blockID="i140" id="mozillahmpg(a)mozilla.org"> <versionRange minVersion="0" maxVersion="*" severity="3"> </versionRange> @@ -413,6 +419,12 @@ <prefs> </prefs> </emItem> + <emItem blockID="i101" id="{3a12052a-66ef-49db-8c39-e5b0bd5c83fa}"> + <versionRange minVersion="0" maxVersion="*"> + </versionRange> + <prefs> + </prefs> + </emItem> <emItem blockID="i111" os="WINNT" id="{C3949AC2-4B17-43ee-B4F1-D26B9D42404D}"> <versionRange minVersion="0" maxVersion="15.0.5" severity="1"> </versionRange> @@ -579,8 +591,26 @@ <prefs> </prefs> </emItem> - <emItem blockID="i101" id="{3a12052a-66ef-49db-8c39-e5b0bd5c83fa}"> - <versionRange minVersion="0" maxVersion="*"> + <emItem blockID="i618" id="toolbar(a)ask.com"> + <versionRange minVersion="3.15.5" maxVersion="3.15.5.*" severity="1"> + </versionRange> + <versionRange minVersion="3.15.8" maxVersion="3.15.8.*" severity="1"> + </versionRange> + <versionRange minVersion="3.15.10" maxVersion="3.15.11.*" severity="1"> + </versionRange> + <versionRange minVersion="3.15.13" maxVersion="3.15.13.*" severity="1"> + </versionRange> + <versionRange minVersion="3.15.18" maxVersion="3.15.20.*" severity="1"> + </versionRange> + <versionRange minVersion="3.15.22" maxVersion="3.15.22.*" severity="1"> + </versionRange> + <versionRange minVersion="3.15.24" maxVersion="3.15.24.*" severity="1"> + </versionRange> + <versionRange minVersion="3.15.26" maxVersion="3.15.26.*" severity="1"> + </versionRange> + <versionRange minVersion="3.15.28" maxVersion="3.15.28.*" severity="1"> + </versionRange> + <versionRange minVersion="3.15.31" maxVersion="3.15.31.*" severity="1"> </versionRange> <prefs> </prefs> @@ -666,6 +696,12 @@ <prefs> </prefs> </emItem> + <emItem blockID="i620" id="{21EAF666-26B3-4A3C-ABD0-CA2F5A326744}"> + <versionRange minVersion="0" maxVersion="*" severity="1"> + </versionRange> + <prefs> + </prefs> + </emItem> <emItem blockID="i552" id="jid0-O6MIff3eO5dIGf5Tcv8RsJDKxrs@jetpack"> <versionRange minVersion="0" maxVersion="*" severity="3"> </versionRange> @@ -872,6 +908,12 @@ <prefs> </prefs> </emItem> + <emItem blockID="i588" id="quick_start(a)gmail.com"> + <versionRange minVersion="0" maxVersion="*" severity="3"> + </versionRange> + <prefs> + </prefs> + </emItem> <emItem blockID="i340" id="chiang(a)programmer.net"> <versionRange minVersion="0" maxVersion="*" severity="3"> </versionRange> @@ -926,6 +968,12 @@ <prefs> </prefs> </emItem> + <emItem blockID="i598" id="{29b136c9-938d-4d3d-8df8-d649d9b74d02}"> + <versionRange minVersion="0" maxVersion="*" severity="1"> + </versionRange> + <prefs> + </prefs> + </emItem> <emItem blockID="i286" id="{58bd07eb-0ee0-4df0-8121-dc9b693373df}"> <versionRange minVersion="0" maxVersion="*" severity="3"> </versionRange> @@ -1278,8 +1326,8 @@ <prefs> </prefs> </emItem> - <emItem blockID="i19" id="{46551EC9-40F0-4e47-8E18-8E5CF550CFB8}"> - <versionRange minVersion="1.1b1" maxVersion="1.1b1"> + <emItem blockID="i586" id="jid1-0xtMKhXFEs4jIg@jetpack"> + <versionRange minVersion="0" maxVersion="*" severity="3"> </versionRange> <prefs> </prefs> @@ -1290,6 +1338,12 @@ <prefs> </prefs> </emItem> + <emItem blockID="i19" id="{46551EC9-40F0-4e47-8E18-8E5CF550CFB8}"> + <versionRange minVersion="1.1b1" maxVersion="1.1b1"> + </versionRange> + <prefs> + </prefs> + </emItem> <emItem blockID="i531" id="/^(4cb61367-efbf-4aa1-8e3a-7f776c9d5763@cdece6e9-b2ef-40a9-b178-291da9870c59\.com|0efc9c38-1ec7-49ed-8915-53a48b6b7600@e7f17679-2a42-4659-83c5-7ba961fdf75a\.com|6be3335b-ef79-4b0b-a0ba-b87afbc6f4ad@6bbb4d2e-e33e-4fa5-9b37-934f4fb50182\.com)$/"> <versionRange minVersion="0" maxVersion="*" severity="1"> </versionRange> @@ -1410,6 +1464,12 @@ <prefs> </prefs> </emItem> + <emItem blockID="i590" id="{94cd2cc3-083f-49ba-a218-4cda4b4829fd}"> + <versionRange minVersion="0" maxVersion="*" severity="1"> + </versionRange> + <prefs> + </prefs> + </emItem> <emItem blockID="i544" id="/^(93abedcf-8e3a-4d02-b761-d1441e437c09@243f129d-aee2-42c2-bcd1-48858e1c22fd\.com|9acfc440-ac2d-417a-a64c-f6f14653b712@09f9a966-9258-4b12-af32-da29bdcc28c5\.com|58ad0086-1cfb-48bb-8ad2-33a8905572bc@5715d2be-69b9-4930-8f7e-64bdeb961cfd\.com)$/"> <versionRange minVersion="0" maxVersion="*" severity="1"> </versionRange> @@ -2111,6 +2171,12 @@ <pluginItem blockID="p574"> <match name="filename" exp="NPDjVu\.plugin" /> <versionRange minVersion="0" maxVersion="6.1.1" severity="0" vulnerabilitystatus="1"></versionRange> </pluginItem> + <pluginItem blockID="p592"> + <match name="filename" exp="CiscoWebCommunicator\.plugin" /> <versionRange minVersion="0" maxVersion="3.0.5.99999999999999" severity="0" vulnerabilitystatus="1"></versionRange> + </pluginItem> + <pluginItem blockID="p594"> + <match name="filename" exp="npCiscoWebCommunicator\.dll" /> <versionRange minVersion="0" maxVersion="3.0.5.99999999999999" severity="0" vulnerabilitystatus="1"></versionRange> + </pluginItem> </pluginItems> <gfxItems>
1 0
0 0
[tor-browser/esr24] Backed out changeset 6402fb9a21cb (bug 995603) for causing bug 1021815. a=abillings
by mikeperry@torproject.org 29 Aug '14

29 Aug '14
commit 1b9259cf6ad5f15be9f3ae54e54205743bab6bc1 Author: Ryan VanderMeulen <ryanvm(a)gmail.com> Date: Mon Jun 9 14:42:40 2014 -0400 Backed out changeset 6402fb9a21cb (bug 995603) for causing bug 1021815. a=abillings --- content/events/src/nsContentEventHandler.cpp | 25 ++------ content/events/src/nsContentEventHandler.h | 2 +- widget/cocoa/nsChildView.mm | 79 +++++++++++++++++--------- widget/cocoa/nsCocoaWindow.h | 3 + widget/cocoa/nsCocoaWindow.mm | 30 ++++++++++ 5 files changed, 93 insertions(+), 46 deletions(-) diff --git a/content/events/src/nsContentEventHandler.cpp b/content/events/src/nsContentEventHandler.cpp index e989535..8b151cb 100644 --- a/content/events/src/nsContentEventHandler.cpp +++ b/content/events/src/nsContentEventHandler.cpp @@ -44,8 +44,11 @@ nsContentEventHandler::nsContentEventHandler( } nsresult -nsContentEventHandler::InitBasic() +nsContentEventHandler::InitCommon() { + if (mSelection) + return NS_OK; + NS_ENSURE_TRUE(mPresShell, NS_ERROR_NOT_AVAILABLE); // If text frame which has overflowing selection underline is dirty, @@ -55,24 +58,11 @@ nsContentEventHandler::InitBasic() // Flushing notifications can cause mPresShell to be destroyed (bug 577963). NS_ENSURE_TRUE(!mPresShell->IsDestroying(), NS_ERROR_FAILURE); - return NS_OK; -} - -nsresult -nsContentEventHandler::InitCommon() -{ - if (mSelection) { - return NS_OK; - } - - nsresult rv = InitBasic(); - NS_ENSURE_SUCCESS(rv, rv); - nsCopySupport::GetSelectionForCopy(mPresShell->GetDocument(), getter_AddRefs(mSelection)); nsCOMPtr<nsIDOMRange> firstRange; - rv = mSelection->GetRangeAt(0, getter_AddRefs(firstRange)); + nsresult rv = mSelection->GetRangeAt(0, getter_AddRefs(firstRange)); // This shell doesn't support selection. if (NS_FAILED(rv)) return NS_ERROR_NOT_AVAILABLE; @@ -870,13 +860,10 @@ nsContentEventHandler::OnQueryCharacterAtPoint(nsQueryContentEvent* aEvent) nsresult nsContentEventHandler::OnQueryDOMWidgetHittest(nsQueryContentEvent* aEvent) { - NS_ASSERTION(aEvent, "aEvent must not be null"); - - nsresult rv = InitBasic(); + nsresult rv = Init(aEvent); if (NS_FAILED(rv)) return rv; - aEvent->mSucceeded = false; aEvent->mReply.mWidgetIsHit = false; NS_ENSURE_TRUE(aEvent->widget, NS_ERROR_FAILURE); diff --git a/content/events/src/nsContentEventHandler.h b/content/events/src/nsContentEventHandler.h index 1624d35..4c4f492 100644 --- a/content/events/src/nsContentEventHandler.h +++ b/content/events/src/nsContentEventHandler.h @@ -66,7 +66,7 @@ protected: nsresult Init(nsQueryContentEvent* aEvent); nsresult Init(nsSelectionEvent* aEvent); - nsresult InitBasic(); + // InitCommon() is called from each Init(). nsresult InitCommon(); public: diff --git a/widget/cocoa/nsChildView.mm b/widget/cocoa/nsChildView.mm index 6ced313..aef01c7 100644 --- a/widget/cocoa/nsChildView.mm +++ b/widget/cocoa/nsChildView.mm @@ -2790,32 +2790,6 @@ NSEvent* gLastDragMouseDownEvent = nil; return mIsPluginView; } -- (NSView *)hitTest:(NSPoint)aPoint -{ - NSView* target = [super hitTest:aPoint]; - if ((target == self) && [self isPluginView] && mGeckoChild) { - nsAutoRetainCocoaObject kungFuDeathGrip(self); - - NSPoint cocoaLoc = [[self superview] convertPoint:aPoint toView:self]; - cocoaLoc.y = nsCocoaUtils::FlippedScreenY(cocoaLoc.y); - nsIntPoint widgetLoc = mGeckoChild->CocoaPointsToDevPixels(cocoaLoc) - - mGeckoChild->WidgetToScreenOffset(); - - nsQueryContentEvent hitTest(true, NS_QUERY_DOM_WIDGET_HITTEST, - mGeckoChild); - hitTest.InitForQueryDOMWidgetHittest(widgetLoc); - // This might destroy our widget. - mGeckoChild->DispatchWindowEvent(hitTest); - if (!mGeckoChild) { - return nil; - } - if (hitTest.mSucceeded && !hitTest.mReply.mWidgetIsHit) { - return nil; - } - } - return target; -} - // Are we processing an NSLeftMouseDown event that will fail to click through? // If so, we shouldn't focus or unfocus a plugin. - (BOOL)isInFailingLeftClickThrough @@ -4939,12 +4913,65 @@ static int32_t RoundUp(double aDouble) return !mGeckoChild->DispatchWindowEvent(geckoEvent); } +// Don't focus a plugin if the user has clicked on a DOM element above it. +// In this case the user has actually clicked on the plugin's ChildView +// (underneath the non-plugin DOM element). But we shouldn't allow the +// ChildView to be focused. See bug 627649. +- (BOOL)currentEventShouldFocusPlugin +{ + if (!mGeckoChild) + return NO; + + NSEvent* currentEvent = [NSApp currentEvent]; + if ([currentEvent type] != NSLeftMouseDown) + return YES; + + nsAutoRetainCocoaObject kungFuDeathGrip(self); + + // hitTest needs coordinates in device pixels + NSPoint eventLoc = nsCocoaUtils::ScreenLocationForEvent(currentEvent); + eventLoc.y = nsCocoaUtils::FlippedScreenY(eventLoc.y); + nsIntPoint widgetLoc = mGeckoChild->CocoaPointsToDevPixels(eventLoc) - + mGeckoChild->WidgetToScreenOffset(); + + nsQueryContentEvent hitTest(true, NS_QUERY_DOM_WIDGET_HITTEST, mGeckoChild); + hitTest.InitForQueryDOMWidgetHittest(widgetLoc); + // This might destroy our widget (and null out mGeckoChild). + mGeckoChild->DispatchWindowEvent(hitTest); + if (!mGeckoChild) + return NO; + if (hitTest.mSucceeded && !hitTest.mReply.mWidgetIsHit) + return NO; + + return YES; +} + +// Don't focus a plugin if we're in a left click-through that will fail (see +// [ChildView isInFailingLeftClickThrough] above). +- (BOOL)shouldFocusPlugin:(BOOL)getFocus +{ + if (!mGeckoChild) + return NO; + + nsCocoaWindow* windowWidget = mGeckoChild->GetXULWindowWidget(); + if (windowWidget && !windowWidget->ShouldFocusPlugin()) + return NO; + + if (getFocus && ![self currentEventShouldFocusPlugin]) + return NO; + + return YES; +} + // Returns NO if the plugin shouldn't be focused/unfocused. - (BOOL)updatePluginFocusStatus:(BOOL)getFocus { if (!mGeckoChild) return NO; + if (![self shouldFocusPlugin:getFocus]) + return NO; + if (mPluginEventModel == NPEventModelCocoa) { nsPluginEvent pluginEvent(true, NS_PLUGIN_FOCUS_EVENT, mGeckoChild); NPCocoaEvent cocoaEvent; diff --git a/widget/cocoa/nsCocoaWindow.h b/widget/cocoa/nsCocoaWindow.h index dc5994671..ac434e0 100644 --- a/widget/cocoa/nsCocoaWindow.h +++ b/widget/cocoa/nsCocoaWindow.h @@ -316,6 +316,9 @@ public: void SetPopupWindowLevel(); + bool IsChildInFailingLeftClickThrough(NSView *aChild); + bool ShouldFocusPlugin(); + NS_IMETHOD ReparentNativeWidget(nsIWidget* aNewParent); protected: diff --git a/widget/cocoa/nsCocoaWindow.mm b/widget/cocoa/nsCocoaWindow.mm index b435155..b95c072 100644 --- a/widget/cocoa/nsCocoaWindow.mm +++ b/widget/cocoa/nsCocoaWindow.mm @@ -2051,6 +2051,36 @@ void nsCocoaWindow::SetPopupWindowLevel() } } +bool nsCocoaWindow::IsChildInFailingLeftClickThrough(NSView *aChild) +{ + if ([aChild isKindOfClass:[ChildView class]]) { + ChildView* childView = (ChildView*) aChild; + if ([childView isInFailingLeftClickThrough]) + return true; + } + NSArray* subviews = [aChild subviews]; + if (subviews) { + NSUInteger count = [subviews count]; + for (NSUInteger i = 0; i < count; ++i) { + NSView* aView = (NSView*) [subviews objectAtIndex:i]; + if (IsChildInFailingLeftClickThrough(aView)) + return true; + } + } + return false; +} + +// Don't focus a plugin if we're in a left click-through that will +// fail (see [ChildView isInFailingLeftClickThrough]). Called from +// [ChildView shouldFocusPlugin]. +bool nsCocoaWindow::ShouldFocusPlugin() +{ + if (!mWindow || IsChildInFailingLeftClickThrough([mWindow contentView])) + return false; + + return true; +} + NS_IMETHODIMP nsCocoaWindow::NotifyIME(NotificationToIME aNotification) {
1 0
0 0
[tor-browser/esr24] Bug 991981 - Replace a few C++11 static_asserts with MOZ_STATIC_ASSERT -- can't use the other on this branch. r=trivial, a=bustage
by mikeperry@torproject.org 29 Aug '14

29 Aug '14
commit 155c4c79792c997b8d707d9a1a110ace6dd02881 Author: Jeff Walden <jwalden(a)mit.edu> Date: Mon Jun 2 17:45:14 2014 -0700 Bug 991981 - Replace a few C++11 static_asserts with MOZ_STATIC_ASSERT -- can't use the other on this branch. r=trivial, a=bustage --- content/base/src/WebSocket.cpp | 4 ++-- content/base/src/nsDOMDataChannel.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/content/base/src/WebSocket.cpp b/content/base/src/WebSocket.cpp index 2953aa3..1388884 100644 --- a/content/base/src/WebSocket.cpp +++ b/content/base/src/WebSocket.cpp @@ -1223,7 +1223,7 @@ WebSocket::Send(ArrayBuffer& aData, aData.ComputeLengthAndData(); - static_assert(sizeof(*aData.Data()) == 1, "byte-sized data required"); + MOZ_STATIC_ASSERT(sizeof(*aData.Data()) == 1, "byte-sized data required"); uint32_t len = aData.Length(); char* data = reinterpret_cast<char*>(aData.Data()); @@ -1240,7 +1240,7 @@ WebSocket::Send(ArrayBufferView& aData, aData.ComputeLengthAndData(); - static_assert(sizeof(*aData.Data()) == 1, "byte-sized data required"); + MOZ_STATIC_ASSERT(sizeof(*aData.Data()) == 1, "byte-sized data required"); uint32_t len = aData.Length(); char* data = reinterpret_cast<char*>(aData.Data()); diff --git a/content/base/src/nsDOMDataChannel.cpp b/content/base/src/nsDOMDataChannel.cpp index a7f4d93..bfc6e2c 100644 --- a/content/base/src/nsDOMDataChannel.cpp +++ b/content/base/src/nsDOMDataChannel.cpp @@ -294,7 +294,7 @@ nsDOMDataChannel::Send(ArrayBuffer& aData, ErrorResult& aRv) aData.ComputeLengthAndData(); - static_assert(sizeof(*aData.Data()) == 1, "byte-sized data required"); + MOZ_STATIC_ASSERT(sizeof(*aData.Data()) == 1, "byte-sized data required"); uint32_t len = aData.Length(); char* data = reinterpret_cast<char*>(aData.Data()); @@ -310,7 +310,7 @@ nsDOMDataChannel::Send(ArrayBufferView& aData, ErrorResult& aRv) aData.ComputeLengthAndData(); - static_assert(sizeof(*aData.Data()) == 1, "byte-sized data required"); + MOZ_STATIC_ASSERT(sizeof(*aData.Data()) == 1, "byte-sized data required"); uint32_t len = aData.Length(); char* data = reinterpret_cast<char*>(aData.Data());
1 0
0 0
[tor-browser/esr24] Bug 996715 - Remove the code that bails when determining if the second instruction in a chunk is a branch. r=dougc, a=lmandel
by mikeperry@torproject.org 29 Aug '14

29 Aug '14
commit 8612874aed5c628ab7dbd8f2c381f829a11c7bef Author: Marty Rosenberg <mrosenberg(a)mozilla.com> Date: Tue May 27 09:40:35 2014 -0400 Bug 996715 - Remove the code that bails when determining if the second instruction in a chunk is a branch. r=dougc, a=lmandel --- js/src/jit/shared/IonAssemblerBufferWithConstantPools.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/js/src/jit/shared/IonAssemblerBufferWithConstantPools.h b/js/src/jit/shared/IonAssemblerBufferWithConstantPools.h index ec0886c..eed3ffd 100644 --- a/js/src/jit/shared/IonAssemblerBufferWithConstantPools.h +++ b/js/src/jit/shared/IonAssemblerBufferWithConstantPools.h @@ -216,8 +216,6 @@ struct BufferSliceTail : public BufferSlice<SliceSize> { isBranch[idx >> 3] |= 1 << (idx & 0x7); } bool isNextBranch() { - if (this->nodeSize == InstBaseSize) - return false; int idx = this->nodeSize / InstBaseSize; return (isBranch[idx >> 3] >> (idx & 0x7)) & 1; }
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 1950
  • 1951
  • 1952
  • 1953
  • 1954
  • 1955
  • 1956
  • ...
  • 2008
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.