diff options
author | Stanisław Pitucha <viraptor@gmail.com> | 2018-07-08 21:01:34 +1000 |
---|---|---|
committer | dormando <dormando@rydia.net> | 2019-08-28 14:36:03 -0700 |
commit | ec34cb718b64dccb91ba440846eafa97aa5ca5db (patch) | |
tree | 4108c0b7d2689294bf0dff421a36c9b512e418a4 /memcached.h | |
parent | 05693047c81a7ace8111d5e541d47f74b1d884a7 (diff) | |
download | memcached-ec34cb718b64dccb91ba440846eafa97aa5ca5db.tar.gz |
Add a handler for seccomp crashes
When seccomp causes a crash, use a SIGSYS action and handle it to print
out an error. Most functions are not allowed at that point (no buffered
output, no ?printf functions, no abort, ...), so the implementation is
as minimal as possible.
Print out a message with the syscall number and exit the process (all
threads).
Diffstat (limited to 'memcached.h')
-rw-r--r-- | memcached.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/memcached.h b/memcached.h index 5f7199c..27ce319 100644 --- a/memcached.h +++ b/memcached.h @@ -819,8 +819,10 @@ void append_stat(const char *name, ADD_STAT add_stats, conn *c, enum store_item_type store_item(item *item, int comm, conn *c); #if HAVE_DROP_PRIVILEGES +extern void setup_privilege_violations_handler(void); extern void drop_privileges(void); #else +#define setup_privilege_violations_handler() #define drop_privileges() #endif |