diff options
author | Dominik Maier <domenukk@gmail.com> | 2020-04-13 20:39:52 +0200 |
---|---|---|
committer | Dominik Maier <domenukk@gmail.com> | 2020-04-13 20:39:52 +0200 |
commit | 1374e65401c9d40b449c78459a2d0241c779b989 (patch) | |
tree | 09aa65b7a14e1b6c499185f90e4fb0751f69113d /src | |
parent | 0fab4e1955b4550a24a1baed2165b4d9ea71b9e1 (diff) | |
download | afl++-1374e65401c9d40b449c78459a2d0241c779b989.tar.gz |
no more waitpid warning
Diffstat (limited to 'src')
-rw-r--r-- | src/afl-forkserver.c | 8 | ||||
-rw-r--r-- | src/afl-showmap.c | 6 | ||||
-rw-r--r-- | src/afl-tmin.c | 4 |
3 files changed, 11 insertions, 7 deletions
diff --git a/src/afl-forkserver.c b/src/afl-forkserver.c index b054a64d..f647ff5d 100644 --- a/src/afl-forkserver.c +++ b/src/afl-forkserver.c @@ -631,8 +631,12 @@ void afl_fsrv_start(afl_forkserver_t *fsrv, char **argv, static void afl_fsrv_kill(afl_forkserver_t *fsrv) { if (fsrv->child_pid > 0) kill(fsrv->child_pid, SIGKILL); - if (fsrv->fsrv_pid > 0) kill(fsrv->fsrv_pid, SIGKILL); - if (waitpid(fsrv->fsrv_pid, NULL, 0) <= 0) { WARNF("error waitpid\n"); } + if (fsrv->fsrv_pid > 0) { + + kill(fsrv->fsrv_pid, SIGKILL); + if (waitpid(fsrv->fsrv_pid, NULL, 0) <= 0) { WARNF("error waitpid\n"); } + + } } diff --git a/src/afl-showmap.c b/src/afl-showmap.c index 9067c2a1..3fcc1d2b 100644 --- a/src/afl-showmap.c +++ b/src/afl-showmap.c @@ -59,9 +59,9 @@ #include <sys/types.h> #include <sys/resource.h> -static char *stdin_file; /* stdin file */ +static char *stdin_file; /* stdin file */ -static u8 *in_dir, /* input folder */ +static u8 *in_dir, /* input folder */ *at_file = NULL; /* Substitution string for @@ */ static u8 *in_data; /* Input data */ @@ -71,7 +71,7 @@ static u32 total, highest; /* tuple content information */ static u32 in_len, /* Input data length */ arg_offset, total_execs; /* Total number of execs */ -static u8 quiet_mode, /* Hide non-essential messages? */ +static u8 quiet_mode, /* Hide non-essential messages? */ edges_only, /* Ignore hit counts? */ raw_instr_output, /* Do not apply AFL filters */ cmin_mode, /* Generate output in afl-cmin mode? */ diff --git a/src/afl-tmin.c b/src/afl-tmin.c index 2df1aed1..31fad1df 100644 --- a/src/afl-tmin.c +++ b/src/afl-tmin.c @@ -60,7 +60,7 @@ static u8 *mask_bitmap; /* Mask for trace bits (-B) */ -static u8 *in_file, /* Minimizer input test case */ +static u8 *in_file, /* Minimizer input test case */ *output_file; /* Minimizer output file */ static u8 *in_data; /* Input data for trimming */ @@ -72,7 +72,7 @@ static u32 in_len, /* Input data length */ missed_crashes, /* Misses due to crashes */ missed_paths; /* Misses due to exec path diffs */ -static u8 crash_mode, /* Crash-centric mode? */ +static u8 crash_mode, /* Crash-centric mode? */ hang_mode, /* Minimize as long as it hangs */ exit_crash, /* Treat non-zero exit as crash? */ edges_only, /* Ignore hit counts? */ |