Merge GECKOVIEW_62_RELBRANCH with default. a=merge GECKOVIEW_62_RELBRANCH
authorRyan VanderMeulen <ryanvm@gmail.com>
Mon, 01 Oct 2018 15:17:42 -0400
branchGECKOVIEW_62_RELBRANCH
changeset 481199 33bec02bb81f
parent 481198 582b268dcabc (current diff)
parent 481197 15f1fe51a2b6 (diff)
child 481204 d335b16bbb7c
push id1810
push userryanvm@gmail.com
push date2018-10-01 19:18 +0000
treeherdermozilla-release@33bec02bb81f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmerge
milestone62.0.3
Merge GECKOVIEW_62_RELBRANCH with default. a=merge
--- a/.hgtags
+++ b/.hgtags
@@ -1267,8 +1267,10 @@ 9cbae12a3fff404ed2c12070ad475424d0ae869f
 9cbae12a3fff404ed2c12070ad475424d0ae869f FIREFOX_62_0_RELEASE
 9cbae12a3fff404ed2c12070ad475424d0ae869f FENNEC_62_0_RELEASE
 4e6207ecd5539d2ca2fe78ac5905d1df4fadc0fb FENNEC_62_0_1_BUILD1
 4e6207ecd5539d2ca2fe78ac5905d1df4fadc0fb FENNEC_62_0_1_RELEASE
 150c70d39363b57ea4e92fbbd900b338f09177d6 FENNEC_62_0_2_BUILD1
 150c70d39363b57ea4e92fbbd900b338f09177d6 FIREFOX_62_0_2_BUILD1
 150c70d39363b57ea4e92fbbd900b338f09177d6 FIREFOX_62_0_2_RELEASE
 150c70d39363b57ea4e92fbbd900b338f09177d6 FENNEC_62_0_2_RELEASE
+c9ed11ae5c79df3dcb69075e1c9da0317d1ecb1b FENNEC_62_0_3_BUILD1
+c9ed11ae5c79df3dcb69075e1c9da0317d1ecb1b FIREFOX_62_0_3_BUILD1
--- a/js/src/jit/BacktrackingAllocator.cpp
+++ b/js/src/jit/BacktrackingAllocator.cpp
@@ -1924,18 +1924,26 @@ BacktrackingAllocator::resolveControlFlo
                 MOZ_ASSERT(predecessor->mir()->numSuccessors() == 1);
 
                 LAllocation* input = phi->getOperand(k);
                 LiveRange* from = vreg(input).rangeFor(exitOf(predecessor), /* preferRegister = */ true);
                 MOZ_ASSERT(from);
 
                 if (!alloc().ensureBallast())
                     return false;
-                if (!moveAtExit(predecessor, from, to, def->type()))
-                    return false;
+                if (mSuccessor->numPredecessors() > 1) {
+                    MOZ_ASSERT(predecessor->mir()->numSuccessors() == 1);
+                    if (!moveAtExit(predecessor, from, to, def->type())) {
+                        return false;
+                    }
+                } else {
+                    if (!moveAtEntry(successor, from, to, def->type())) {
+                        return false;
+                    }
+                }
             }
         }
     }
 
     // Add moves to resolve graph edges with different allocations at their
     // source and target.
     for (size_t i = 1; i < graph.numVirtualRegisters(); i++) {
         VirtualRegister& reg = vregs[i];
--- a/js/src/jit/MCallOptimize.cpp
+++ b/js/src/jit/MCallOptimize.cpp
@@ -786,16 +786,22 @@ IonBuilder::InliningResult
 IonBuilder::inlineArrayPush(CallInfo& callInfo)
 {
     const uint32_t inlineArgsLimit = 10;
     if (callInfo.argc() < 1 || callInfo.argc() > inlineArgsLimit || callInfo.constructing()) {
         trackOptimizationOutcome(TrackedOutcome::CantInlineNativeBadForm);
         return InliningStatus_NotInlined;
     }
 
+    // XXX bug 1493903.
+    if (callInfo.argc() != 1) {
+        trackOptimizationOutcome(TrackedOutcome::CantInlineNativeBadForm);
+        return InliningStatus_NotInlined;
+    }
+
     MDefinition* obj = convertUnboxedObjects(callInfo.thisArg());
     for (uint32_t i = 0; i < callInfo.argc(); i++) {
         MDefinition* value = callInfo.getArg(i);
         if (PropertyWriteNeedsTypeBarrier(alloc(), constraints(), current,
                                           &obj, nullptr, &value, /* canModify = */ false))
         {
             trackOptimizationOutcome(TrackedOutcome::NeedsTypeBarrier);
             return InliningStatus_NotInlined;
--- a/security/sandbox/mac/SandboxPolicies.h
+++ b/security/sandbox/mac/SandboxPolicies.h
@@ -787,27 +787,32 @@ static const char flashPluginSandboxRule
   (allow file-read*
       (literal "/Library/PreferencePanes/Flash Player.prefPane")
       (home-library-literal "/PreferencePanes/Flash Player.prefPane")
       (home-library-regex "/Application Support/Macromedia/ss\.(cfg|cfn|sgn)$"))
 
   (allow file-read*
       (literal "/Library/Preferences/com.apple.security.plist")
       (subpath "/private/var/db/mds"))
-  ; Tests revealed file-write-{data,create,flags} required for some encrypted
-  ; video playback. Allowing file-write* to match system profiles.
+
+  ; Additional read/write paths needed for encrypted video playback.
+  ; Tests revealed file-write-{data,create,flags} are required for the
+  ; accesses to the mds files. file-write-{data,create,mode,unlink}
+  ; required for CertStore.dat access. Allow file-write* to match system
+  ; profiles and for better compatibilty.
   (allow file-read* file-write*
       (require-all
           (vnode-type REGULAR-FILE)
           (require-any
               (cache-literal "/mds/mds.lock")
               (cache-literal "/mds/mdsDirectory.db")
               (cache-literal "/mds/mdsDirectory.db_")
               (cache-literal "/mds/mdsObject.db")
-              (cache-literal "/mds/mdsObject.db_"))))
+              (cache-literal "/mds/mdsObject.db_")
+              (tempDir-regex "/TemporaryItems/[^/]+/CertStore.dat"))))
 
   (allow network-bind (local ip))
 
   (deny file-write-create (vnode-type SYMLINK))
 )SANDBOX_LITERAL";
 
 }
 
--- a/taskcluster/taskgraph/actions/registry.py
+++ b/taskcluster/taskgraph/actions/registry.py
@@ -17,17 +17,17 @@ from taskgraph.config import load_graph_
 from taskgraph.util import taskcluster, yaml, hash
 from taskgraph.parameters import Parameters
 from mozbuild.util import memoize
 
 
 actions = []
 callbacks = {}
 
-Action = namedtuple('Action', ['order', 'cb_name', 'generic', 'action_builder'])
+Action = namedtuple('Action', ['order', 'kind', 'cb_name', 'generic', 'action_builder'])
 
 
 def is_json(data):
     """ Return ``True``, if ``data`` is a JSON serializable data structure. """
     try:
         json.dumps(data)
     except ValueError:
         return False
@@ -263,17 +263,17 @@ def register_callback_action(name, title
                             'taskId': {'$eval': 'taskId'},  # target taskId (or null)
                             'taskGroupId': {'$eval': 'taskGroupId'},  # target task group
                         }
                     },
                 })
 
             return rv
 
-        actions.append(Action(order, cb_name, generic, action_builder))
+        actions.append(Action(order, kind, cb_name, generic, action_builder))
 
         mem['registered'] = True
         callbacks[cb_name] = cb
     return register_callback
 
 
 def render_actions_json(parameters, graph_config):
     """
@@ -313,16 +313,19 @@ def sanity_check_task_scope(callback, pa
     prevent serious damage from such abuse, it's never a valid thing to do.
     """
     for action in _get_actions(graph_config):
         if action.cb_name == callback:
             break
     else:
         raise Exception('No action with cb_name {}'.format(callback))
 
+    if action.kind == 'task':
+        return  # task kinds don't have sane scopes, so bail out
+
     actionPerm = 'generic' if action.generic else action.cb_name
 
     repo_param = '{}head_repository'.format(graph_config['project-repo-param-prefix'])
     head_repository = parameters[repo_param]
     assert head_repository.startswith('https://hg.mozilla.org/')
     expected_scope = 'assume:repo:{}:action:{}'.format(head_repository[8:], actionPerm)
 
     # the scope should appear literally; no need for a satisfaction check. The use of
--- a/toolkit/components/search/nsSearchService.js
+++ b/toolkit/components/search/nsSearchService.js
@@ -3140,16 +3140,20 @@ SearchService.prototype = {
 
   _blackList: [
     "blacklist=true",
     "hspart=lvs",
     "form=CONBDF",
     "clid=2308146",
     "fr=mcafee",
     "PC=MC0",
+    "secure.webofsearch.com",
+    "secure.startpageweb.com",
+    "secure.webstartsearch.com",
+    "secure.startwebsearch.com",
   ],
 
   _addEngineToStore: function SRCH_SVC_addEngineToStore(aEngine) {
     let url = aEngine._getURLOfType("text/html").getSubmission("dummy", aEngine).uri.spec;
     if (this._blackList.some(code => url.includes(code))) {
       LOG("_addEngineToStore: Ignoring blacklisted engine");
       return;
     }
--- a/widget/cocoa/nsChildView.mm
+++ b/widget/cocoa/nsChildView.mm
@@ -441,23 +441,16 @@ nsChildView::Create(nsIWidget* aParent,
   // we need to provide an autorelease pool to avoid leaking cocoa objects
   // (see bug 559075).
   nsAutoreleasePool localPool;
 
   // See NSView (MethodSwizzling) below.
   if (!gChildViewMethodsSwizzled) {
     nsToolkit::SwizzleMethods([NSView class], @selector(mouseDownCanMoveWindow),
                               @selector(nsChildView_NSView_mouseDownCanMoveWindow));
-#ifdef __LP64__
-    nsToolkit::SwizzleMethods([NSEvent class], @selector(addLocalMonitorForEventsMatchingMask:handler:),
-                              @selector(nsChildView_NSEvent_addLocalMonitorForEventsMatchingMask:handler:),
-                              true);
-    nsToolkit::SwizzleMethods([NSEvent class], @selector(removeMonitor:),
-                              @selector(nsChildView_NSEvent_removeMonitor:), true);
-#endif
     gChildViewMethodsSwizzled = true;
   }
 
   mBounds = aRect;
 
   // Ensure that the toolkit is created.
   nsToolkit::GetToolkit();
 
@@ -7207,53 +7200,8 @@ static const CGEventField kCGWindowNumbe
   NSWindow *ourWindow = [self window];
   NSView *contentView = [ourWindow contentView];
   if ([ourWindow isKindOfClass:[ToolbarWindow class]] && (self == contentView))
     return [ourWindow isMovableByWindowBackground];
   return [self nsChildView_NSView_mouseDownCanMoveWindow];
 }
 
 @end
-
-#ifdef __LP64__
-// When using blocks, at least on OS X 10.7, the OS sometimes calls
-// +[NSEvent removeMonitor:] more than once on a single event monitor, which
-// causes crashes.  See bug 678607.  We hook these methods to work around
-// the problem.
-@interface NSEvent (MethodSwizzling)
-+ (id)nsChildView_NSEvent_addLocalMonitorForEventsMatchingMask:(unsigned long long)mask handler:(id)block;
-+ (void)nsChildView_NSEvent_removeMonitor:(id)eventMonitor;
-@end
-
-// This is a local copy of the AppKit frameworks sEventObservers hashtable.
-// It only stores "local monitors".  We use it to ensure that +[NSEvent
-// removeMonitor:] is never called more than once on the same local monitor.
-static NSHashTable *sLocalEventObservers = nil;
-
-@implementation NSEvent (MethodSwizzling)
-
-+ (id)nsChildView_NSEvent_addLocalMonitorForEventsMatchingMask:(unsigned long long)mask handler:(id)block
-{
-  if (!sLocalEventObservers) {
-    sLocalEventObservers = [[NSHashTable hashTableWithOptions:
-      NSHashTableStrongMemory | NSHashTableObjectPointerPersonality] retain];
-  }
-  id retval =
-    [self nsChildView_NSEvent_addLocalMonitorForEventsMatchingMask:mask handler:block];
-  if (sLocalEventObservers && retval && ![sLocalEventObservers containsObject:retval]) {
-    [sLocalEventObservers addObject:retval];
-  }
-  return retval;
-}
-
-+ (void)nsChildView_NSEvent_removeMonitor:(id)eventMonitor
-{
-  if (sLocalEventObservers && [eventMonitor isKindOfClass: ::NSClassFromString(@"_NSLocalEventObserver")]) {
-    if (![sLocalEventObservers containsObject:eventMonitor]) {
-      return;
-    }
-    [sLocalEventObservers removeObject:eventMonitor];
-  }
-  [self nsChildView_NSEvent_removeMonitor:eventMonitor];
-}
-
-@end
-#endif // #ifdef __LP64__