bug 555674 - fix some bugs in the Breakpad Linux/ARM code. r=jimb
authorTed Mielczarek <ted.mielczarek@gmail.com>
Fri, 26 Mar 2010 14:23:48 -0400
changeset 40608 8a97fc25da6fc4d2b91a02145887cd291e6753b3
parent 40607 9707858ee63b34f290f3e156ef5e81f0cc9ca0ac
child 40609 78bb9d51051c8dfefa9ca98a687cca2a630c2f88
push idunknown
push userunknown
push dateunknown
reviewersjimb
bugs555674
milestone1.9.3a5pre
bug 555674 - fix some bugs in the Breakpad Linux/ARM code. r=jimb
toolkit/crashreporter/client/crashreporter_gtk_common.cpp
toolkit/crashreporter/client/crashreporter_unix_common.cpp
toolkit/crashreporter/google-breakpad/src/common/linux/linux_syscall_support.h
--- a/toolkit/crashreporter/google-breakpad/src/common/linux/linux_syscall_support.h
+++ b/toolkit/crashreporter/google-breakpad/src/common/linux/linux_syscall_support.h
@@ -1634,17 +1634,17 @@ struct kernel_statfs {
                              /* Call _exit(%r0).
                               */
                              __syscall(exit)"\n"
                            "1:\n"
                              : "=r" (__res)
                              : "i"(-EINVAL),
                                "r"(fn), "r"(__stack), "r"(__flags), "r"(arg),
                                "r"(__ptid), "r"(__tls), "r"(__ctid)
-                             : "lr", "memory");
+                             : "cc", "lr", "memory");
       }
       LSS_RETURN(int, __res);
     }
   #elif defined(__ARM_EABI__)
     /* Most definitions of _syscallX() neglect to mark "memory" as being
      * clobbered. This causes problems with compilers, that do a better job
      * at optimizing across __asm__ calls.
      * So, we just have to redefine all fo the _syscallX() macros.
@@ -1763,17 +1763,17 @@ struct kernel_statfs {
                              "mov r7, %10\n"
                              "swi 0x0\n"
                            "1:\n"
                              : "=r" (__res)
                              : "i"(-EINVAL),
                                "r"(fn), "r"(__stack), "r"(__flags), "r"(arg),
                                "r"(__ptid), "r"(__tls), "r"(__ctid),
                                "i"(__NR_clone), "i"(__NR_exit)
-                             : "lr", "memory");
+                             : "cc", "r7", "lr", "memory");
       }
       LSS_RETURN(int, __res);
     }
   #elif defined(__mips__)
     #undef LSS_REG
     #define LSS_REG(r,a) register unsigned long __r##r __asm__("$"#r) =       \
                                  (unsigned long)(a)
     #undef  LSS_BODY
@@ -2721,26 +2721,26 @@ struct kernel_statfs {
 
     LSS_INLINE int LSS_NAME(socketpair)(int d, int type, int protocol,
                                         int sv[2]) {
       LSS_SC_BODY(4, int, 8, d, type, protocol, sv);
     }
   #endif
   #if defined(__ARM_EABI__)
     LSS_INLINE _syscall3(ssize_t, recvmsg, int, s, struct kernel_msghdr*, msg,
-                         int, flags);
+                         int, flags)
     LSS_INLINE _syscall3(ssize_t, sendmsg, int, s, const struct kernel_msghdr*,
-                         msg, int, flags);
+                         msg, int, flags)
     LSS_INLINE _syscall6(ssize_t, sendto, int, s, const void*, buf, size_t, len,
                          int, falgs, const struct kernel_sockaddr*, to,
-                         unsigned int, tolen);
-    LSS_INLINE _syscall2(int, shutdown, int, s, int, how);
-    LSS_INLINE _syscall3(int, socket, int, domain, int, type, int, protocol);
+                         unsigned int, tolen)
+    LSS_INLINE _syscall2(int, shutdown, int, s, int, how)
+    LSS_INLINE _syscall3(int, socket, int, domain, int, type, int, protocol)
     LSS_INLINE _syscall4(int, socketpair, int, d, int, type, int, protocol, 
-                         int*, sv);
+                         int*, sv)
   #endif
   #if defined(__i386__) || defined(__ARM_ARCH_3__) ||                      \
       (defined(__mips__) && _MIPS_SIM == _MIPS_SIM_ABI32)
     #define __NR__socketcall  __NR_socketcall
     LSS_INLINE _syscall2(int,      _socketcall,    int,   c,
                          va_list,                  a)
     LSS_INLINE int LSS_NAME(socketcall)(int op, ...) {
       int rc;