aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorted.mielczarek@gmail.com <ted.mielczarek@gmail.com@4c0a9323-5329-0410-9bdc-e9ce6186880e>2013-04-18 12:47:08 +0000
committerted.mielczarek@gmail.com <ted.mielczarek@gmail.com@4c0a9323-5329-0410-9bdc-e9ce6186880e>2013-04-18 12:47:08 +0000
commit32ce6dea5131072173797fccb1dff44038f77d74 (patch)
tree4d9d1dd8d765bd1bbf1a91f49653264f3e2d1d1c /src
parentminidump_stackwalk should display r12 in ARM stack traces (diff)
downloadbreakpad-32ce6dea5131072173797fccb1dff44038f77d74.tar.xz
Fix missing result check in Mac exception handler
Patch by Georg Fritzsche <georg.fritzsche@googlemail.com>, R=ted at https://breakpad.appspot.com/554003/ git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1152 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src')
-rw-r--r--src/client/mac/handler/exception_handler.cc10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/client/mac/handler/exception_handler.cc b/src/client/mac/handler/exception_handler.cc
index 68623222..ebaf857e 100644
--- a/src/client/mac/handler/exception_handler.cc
+++ b/src/client/mac/handler/exception_handler.cc
@@ -281,9 +281,13 @@ bool ExceptionHandler::WriteMinidump(bool write_exception_stream) {
if (pthread_mutex_lock(&minidump_write_mutex_) == 0) {
// Send an empty message to the handle port so that a minidump will
// be written
- SendMessageToHandlerThread(write_exception_stream ?
- kWriteDumpWithExceptionMessage :
- kWriteDumpMessage);
+ bool result = SendMessageToHandlerThread(write_exception_stream ?
+ kWriteDumpWithExceptionMessage :
+ kWriteDumpMessage);
+ if (!result) {
+ pthread_mutex_unlock(&minidump_write_mutex_);
+ return false;
+ }
// Wait for the minidump writer to complete its writing. It will unlock
// the mutex when completed