mirror of
https://github.com/chromium/crashpad.git
synced 2024-12-27 15:32:10 +08:00
Add external CrashpadHandlerMain declaration
External callers might also want to call CrashpadHandlerMain, so provide an externally visibile declaration on Android. Bug: 973167 Change-Id: Ib9c2a2070e87563acd8af25f8634f1c88ce6681f Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/1707897 Reviewed-by: Mark Mentovai <mark@chromium.org> Commit-Queue: Vlad Tsyrklevich <vtsyrklevich@chromium.org>
This commit is contained in:
parent
79b59b0a8f
commit
2fb8f98d67
@ -17,17 +17,13 @@
|
||||
namespace crashpad {
|
||||
|
||||
extern "C" {
|
||||
//! \brief The `main()` entry point for Android libraries.
|
||||
//!
|
||||
//! This symbol is the entry point for crashpad when it is dynamically loaded
|
||||
//! using /system/bin/linker.
|
||||
//!
|
||||
//! \sa CrashpadClient::StartHandlerWithLinkerAtCrash()
|
||||
|
||||
__attribute__((visibility("default"), used)) int CrashpadHandlerMain(
|
||||
int argc,
|
||||
char* argv[]) {
|
||||
return HandlerMain(argc, argv, nullptr);
|
||||
}
|
||||
|
||||
} // extern "C"
|
||||
|
||||
} // namespace crashpad
|
||||
|
@ -15,6 +15,7 @@
|
||||
#ifndef CRASHPAD_HANDLER_HANDLER_MAIN_H_
|
||||
#define CRASHPAD_HANDLER_HANDLER_MAIN_H_
|
||||
|
||||
#include "build/build_config.h"
|
||||
#include "handler/user_stream_data_source.h"
|
||||
|
||||
namespace crashpad {
|
||||
@ -34,6 +35,16 @@ int HandlerMain(int argc,
|
||||
char* argv[],
|
||||
const UserStreamDataSources* user_stream_sources);
|
||||
|
||||
#if defined(OS_ANDROID)
|
||||
//! \brief The `main()` entry point for Android libraries.
|
||||
//!
|
||||
//! This symbol is the entry point for crashpad when it is dynamically loaded
|
||||
//! using /system/bin/linker.
|
||||
//!
|
||||
//! \sa CrashpadClient::StartHandlerWithLinkerAtCrash()
|
||||
extern "C" int CrashpadHandlerMain(int argc, char* argv[]);
|
||||
#endif
|
||||
|
||||
} // namespace crashpad
|
||||
|
||||
#endif // CRASHPAD_HANDLER_HANDLER_MAIN_H_
|
||||
|
Loading…
x
Reference in New Issue
Block a user