remove warnings

This commit is contained in:
vanhauser-thc
2021-03-25 08:40:33 +01:00
parent 55224e5150
commit ab394836a9
6 changed files with 27 additions and 15 deletions

View File

@ -380,6 +380,7 @@ void afl_fsrv_start(afl_forkserver_t *fsrv, char **argv,
}
}
#endif
if (fsrv->use_fauxsrv) {
@ -1073,6 +1074,7 @@ void afl_fsrv_write_to_testcase(afl_forkserver_t *fsrv, u8 *buf, size_t len) {
}
}
#endif
if (likely(fsrv->use_shmem_fuzz && fsrv->shmem_fuzz)) {
@ -1206,6 +1208,7 @@ fsrv_run_result_t afl_fsrv_run_target(afl_forkserver_t *fsrv, u32 timeout,
fsrv->persistent_record_len[idx] = val;
}
#endif
if (fsrv->child_pid <= 0) {
@ -1336,6 +1339,7 @@ fsrv_run_result_t afl_fsrv_run_target(afl_forkserver_t *fsrv, u32 timeout,
++fsrv->persistent_record_cnt;
}
#endif
/* For a proper crash, set last_kill_signal to WTERMSIG, else set it to 0 */

View File

@ -1034,7 +1034,7 @@ int main(int argc, char **argv_orig, char **envp) {
if (unlikely(afl->afl_env.afl_persistent_record)) {
#ifdef AFL_PERSISTENT_RECORD
#ifdef AFL_PERSISTENT_RECORD
afl->fsrv.persistent_record = atoi(afl->afl_env.afl_persistent_record);
@ -1046,11 +1046,13 @@ int main(int argc, char **argv_orig, char **envp) {
}
#else
#else
FATAL("afl-fuzz was not compiled with AFL_PERSISTENT_RECORD enabled in config.h!");
FATAL(
"afl-fuzz was not compiled with AFL_PERSISTENT_RECORD enabled in "
"config.h!");
#endif
#endif
}
@ -1520,6 +1522,7 @@ int main(int argc, char **argv_orig, char **envp) {
check_binary(afl, argv[optind]);
#ifdef AFL_PERSISTENT_RECORD
if (unlikely(afl->fsrv.persistent_record)) {
if (!getenv(PERSIST_ENV_VAR)) {
@ -1534,6 +1537,8 @@ int main(int argc, char **argv_orig, char **envp) {
}
#endif
if (afl->shmem_testcase_mode) { setup_testcase_shmem(afl); }
afl->start_time = get_cur_time();

View File

@ -955,7 +955,6 @@ int main(int argc, char **argv_orig, char **envp) {
}
if (in_dir) {
/* If we don't have a file name chosen yet, use a safe default. */