components/desktop/thunderbird/patches/firefox31-317-sparc-xptcall.patch
author Stacy Yeh <stacy.yeh@oracle.com>
Mon, 11 Jan 2016 09:27:45 -0800
changeset 5255 cea0e462549a
permissions -rw-r--r--
22322082 Move Firefox/Thunderbird from Desktop consolidation to Userland

See Mozilla bug #1153707 - [JavaScript Error: "invalid 'in' operand 
aLivemarkInfo"] when calling method: [mozIAsyncLivemarks::getLivemark].
This is already upstream in version 38.

--- comm-esr31/mozilla/xpcom/reflect/xptcall/src/md/unix/xptcstubs_sparc_solaris.cpp.orig	2015-06-04 17:42:52.730766562 -0700
+++ comm-esr31/mozilla/xpcom/reflect/xptcall/src/md/unix/xptcstubs_sparc_solaris.cpp	2015-06-04 17:42:52.738654394 -0700
@@ -52,13 +52,17 @@
 
         if(param.IsOut() || !type.IsArithmetic())
         {
-            dp->val.p = (void*) *ap;
+            if (type == nsXPTType::T_JSVAL)
+                dp->val.p = *((void**)*ap);
+            else
+                dp->val.p = (void*) *ap;
+
             continue;
         }
         // else
         switch(type)
         {
-        case nsXPTType::T_I8     : dp->val.i8  = *((int32_t*)  ap);       break;
+        case nsXPTType::T_I8     : dp->val.i8  = *((int32_t*) ap);       break;
         case nsXPTType::T_I16    : dp->val.i16 = *((int32_t*) ap);       break;
         case nsXPTType::T_I32    : dp->val.i32 = *((int32_t*) ap);       break;
         case nsXPTType::T_DOUBLE :
--- comm-esr31/mozilla/js/xpconnect/src/XPCWrappedJSClass.cpp.orig	2015-06-04 17:42:52.736217989 -0700
+++ comm-esr31/mozilla/js/xpconnect/src/XPCWrappedJSClass.cpp	2015-06-04 17:42:52.739152339 -0700
@@ -1357,21 +1357,9 @@
                 break;
         }
 
-// see bug #961488
-#if (defined(XP_UNIX) && !defined(XP_MACOSX) && !defined(_AIX)) && \
-    ((defined(__sparc) && !defined(__sparcv9) && !defined(__sparcv9__)) || \
-    (defined(__powerpc__) && !defined (__powerpc64__)))
-        if (type_tag == nsXPTType::T_JSVAL) {
-            if (!XPCConvert::JSData2Native(*(void**)(&pv->val), val, type,
-                                           !param.IsDipper(), &param_iid, nullptr))
-                break;
-        } else
-#endif
-        {
-            if (!XPCConvert::JSData2Native(&pv->val, val, type,
-                                           !param.IsDipper(), &param_iid, nullptr))
-                break;
-        }
+        if (!XPCConvert::JSData2Native(&pv->val, val, type,
+                                       !param.IsDipper(), &param_iid, nullptr))
+            break;
     }
 
     // if any params were dependent, then we must iterate again to convert them.