diff options
author | ted.mielczarek <ted.mielczarek@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2010-10-20 15:51:38 +0000 |
---|---|---|
committer | ted.mielczarek <ted.mielczarek@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2010-10-20 15:51:38 +0000 |
commit | cfc8628092e17069d8d6c7068d4f21d9baabe077 (patch) | |
tree | 43e9d016602ec4944511a3f02981a004a6225ef5 /src/client/linux/handler/exception_handler.cc | |
parent | Double stack scanning length in stackwalker (diff) | |
download | breakpad-cfc8628092e17069d8d6c7068d4f21d9baabe077.tar.xz |
Add support for building the Linux client code using the Android NDK
r=mwu at http://breakpad.appspot.com/212001/show
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@716 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/client/linux/handler/exception_handler.cc')
-rw-r--r-- | src/client/linux/handler/exception_handler.cc | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/client/linux/handler/exception_handler.cc b/src/client/linux/handler/exception_handler.cc index 57da0c56..592c9e5b 100644 --- a/src/client/linux/handler/exception_handler.cc +++ b/src/client/linux/handler/exception_handler.cc @@ -73,12 +73,18 @@ #include <stdio.h> #include <sys/mman.h> #include <sys/prctl.h> +#if !defined(__ANDROID__) #include <sys/signal.h> +#endif #include <sys/syscall.h> +#if !defined(__ANDROID__) #include <sys/ucontext.h> #include <sys/user.h> +#endif #include <sys/wait.h> +#if !defined(__ANDROID__) #include <ucontext.h> +#endif #include <unistd.h> #include <algorithm> @@ -186,7 +192,7 @@ bool ExceptionHandler::InstallHandlers() { stack.ss_sp = signal_stack; stack.ss_size = kSigStackSize; - if (sigaltstack(&stack, NULL) == -1) + if (sys_sigaltstack(&stack, NULL) == -1) return false; struct sigaction sa; @@ -322,7 +328,7 @@ bool ExceptionHandler::HandleSignal(int sig, siginfo_t* info, void* uc) { return false; // Allow ourselves to be dumped. - prctl(PR_SET_DUMPABLE, 1); + sys_prctl(PR_SET_DUMPABLE, 1); CrashContext context; memcpy(&context.siginfo, info, sizeof(siginfo_t)); memcpy(&context.context, uc, sizeof(struct ucontext)); |