mirror of
https://github.com/chromium/crashpad.git
synced 2025-01-14 09:17:57 +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 {
|
namespace crashpad {
|
||||||
|
|
||||||
extern "C" {
|
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(
|
__attribute__((visibility("default"), used)) int CrashpadHandlerMain(
|
||||||
int argc,
|
int argc,
|
||||||
char* argv[]) {
|
char* argv[]) {
|
||||||
return HandlerMain(argc, argv, nullptr);
|
return HandlerMain(argc, argv, nullptr);
|
||||||
}
|
}
|
||||||
|
|
||||||
} // extern "C"
|
} // extern "C"
|
||||||
|
|
||||||
} // namespace crashpad
|
} // namespace crashpad
|
||||||
|
@ -15,6 +15,7 @@
|
|||||||
#ifndef CRASHPAD_HANDLER_HANDLER_MAIN_H_
|
#ifndef CRASHPAD_HANDLER_HANDLER_MAIN_H_
|
||||||
#define CRASHPAD_HANDLER_HANDLER_MAIN_H_
|
#define CRASHPAD_HANDLER_HANDLER_MAIN_H_
|
||||||
|
|
||||||
|
#include "build/build_config.h"
|
||||||
#include "handler/user_stream_data_source.h"
|
#include "handler/user_stream_data_source.h"
|
||||||
|
|
||||||
namespace crashpad {
|
namespace crashpad {
|
||||||
@ -34,6 +35,16 @@ int HandlerMain(int argc,
|
|||||||
char* argv[],
|
char* argv[],
|
||||||
const UserStreamDataSources* user_stream_sources);
|
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
|
} // namespace crashpad
|
||||||
|
|
||||||
#endif // CRASHPAD_HANDLER_HANDLER_MAIN_H_
|
#endif // CRASHPAD_HANDLER_HANDLER_MAIN_H_
|
||||||
|
Loading…
x
Reference in New Issue
Block a user