Small debuggerd improvements.
Include the ABI in seccomp causes.
Slightly improved command-line usage information.
Fix crasher for seccomp failures.
Bug: N/A
Test: crasher
Change-Id: Ie419ecfe72ee4f5ccf49c927be18350a58a66a90
diff --git a/debuggerd/crasher/Android.bp b/debuggerd/crasher/Android.bp
index 4727894..f73f672 100644
--- a/debuggerd/crasher/Android.bp
+++ b/debuggerd/crasher/Android.bp
@@ -48,6 +48,7 @@
shared_libs: [
"libbase",
"liblog",
+ "libseccomp_policy",
],
multilib: {
lib32: {
@@ -69,6 +70,7 @@
"libdebuggerd_handler",
"libbase",
"liblog",
+ "libseccomp_policy",
],
multilib: {
lib32: {
diff --git a/debuggerd/crasher/crasher.cpp b/debuggerd/crasher/crasher.cpp
index 1c01e3e..6970201 100644
--- a/debuggerd/crasher/crasher.cpp
+++ b/debuggerd/crasher/crasher.cpp
@@ -33,6 +33,8 @@
#include <android-base/logging.h>
#include <log/log.h>
+#include "seccomp_policy.h"
+
#if defined(STATIC_CRASHER)
#include "debuggerd/handler.h"
#endif
@@ -269,6 +271,7 @@
munmap(map, sizeof(int));
map[0] = '8';
} else if (!strcasecmp(arg, "seccomp")) {
+ set_seccomp_filter();
syscall(99999);
#if defined(__arm__)
} else if (!strcasecmp(arg, "kuser_helper_version")) {