mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-07 23:43:37 +00:00
Bug 824224: Make mozalloc_abort() not MOZ_NORETURN and log errors to logcat. r=glandium
This commit is contained in:
parent
19cc88082d
commit
36428f7dd6
@ -9,17 +9,24 @@
|
||||
# define MOZALLOC_EXPORT __declspec(dllexport)
|
||||
#endif
|
||||
|
||||
#include "mozilla/Assertions.h"
|
||||
#include "mozilla/mozalloc_abort.h"
|
||||
|
||||
#ifdef ANDROID
|
||||
# include <android/log.h>
|
||||
#endif
|
||||
#include <stdio.h>
|
||||
|
||||
#include "mozilla/mozalloc_abort.h"
|
||||
#include "mozilla/Assertions.h"
|
||||
|
||||
void
|
||||
mozalloc_abort(const char* const msg)
|
||||
{
|
||||
#ifndef ANDROID
|
||||
fputs(msg, stderr);
|
||||
fputs("\n", stderr);
|
||||
#else
|
||||
__android_log_print(ANDROID_LOG_ERROR, "Gecko", "mozalloc_abort: %s", msg);
|
||||
#endif
|
||||
MOZ_CRASH();
|
||||
}
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
* Terminate this process in such a way that breakpad is triggered, if
|
||||
* at all possible.
|
||||
*/
|
||||
MOZ_NORETURN MOZALLOC_EXPORT void mozalloc_abort(const char* const msg);
|
||||
MOZALLOC_EXPORT void mozalloc_abort(const char* const msg);
|
||||
|
||||
|
||||
#endif /* ifndef mozilla_mozalloc_abort_h */
|
||||
|
Loading…
x
Reference in New Issue
Block a user