diff options
author | van Hauser <vh@thc.org> | 2022-10-24 20:46:31 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-24 20:46:31 +0200 |
commit | a075cddef6ae71516a960116f3d944efd5671e5d (patch) | |
tree | 724dd6978ebb10f52c4bdda86eb44a5494b33409 /include/common.h | |
parent | d1e1bbc713b22d620956143634ecdf97223aa59f (diff) | |
parent | 05e0825d66d938308842c25c4c74b5cdd4a885eb (diff) | |
download | afl++-a075cddef6ae71516a960116f3d944efd5671e5d.tar.gz |
Merge pull request #1561 from AFLplusplus/dev
push to stable
Diffstat (limited to 'include/common.h')
-rw-r--r-- | include/common.h | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/include/common.h b/include/common.h index a983bb0e..f6d1dd1a 100644 --- a/include/common.h +++ b/include/common.h @@ -32,6 +32,7 @@ #include <unistd.h> #include <sys/time.h> #include <stdbool.h> +#include "forkserver.h" #include "types.h" /* STRINGIFY_VAL_SIZE_MAX will fit all stringify_ strings. */ @@ -67,10 +68,18 @@ u8 *find_binary(u8 *fname); u8 *find_afl_binary(u8 *own_loc, u8 *fname); -/* Parses the kill signal environment variable, FATALs on error. - If the env is not set, sets the env to default_signal for the signal handlers - and returns the default_signal. */ -int parse_afl_kill_signal_env(u8 *afl_kill_signal_env, int default_signal); +/* Parses the (numeric) kill signal environment variable passed + via `numeric_signal_as_str`. + If NULL is passed, the `default_signal` value is returned. + FATALs if `numeric_signal_as_str` is not a valid integer .*/ +int parse_afl_kill_signal(u8 *numeric_signal_as_str, int default_signal); + +/* Configure the signals that are used to kill the forkserver + and the forked childs. If `afl_kill_signal_env` or `afl_fsrv_kill_signal_env` + is NULL, the appropiate values are read from the environment. */ +void configure_afl_kill_signals(afl_forkserver_t *fsrv, + char *afl_kill_signal_env, + char *afl_fsrv_kill_signal_env); /* Read a bitmap from file fname to memory This is for the -B option again. */ |