mirror of
https://github.com/AFLplusplus/AFLplusplus.git
synced 2025-06-16 03:48:08 +00:00
fixes
This commit is contained in:
@ -1278,7 +1278,7 @@ fsrv_run_result_t afl_fsrv_run_target(afl_forkserver_t *fsrv, u32 timeout,
|
|||||||
snprintf(fn, sizeof(fn), "%s/RECORD:%06u,cnt:%06u",
|
snprintf(fn, sizeof(fn), "%s/RECORD:%06u,cnt:%06u",
|
||||||
fsrv->persistent_record_dir, fsrv->persistent_record_cnt,
|
fsrv->persistent_record_dir, fsrv->persistent_record_cnt,
|
||||||
writecnt++);
|
writecnt++);
|
||||||
int fd = open(fn, O_WRONLY, 0644);
|
int fd = open(fn, O_CREAT | O_TRUNC | O_WRONLY, 0644);
|
||||||
if (fd >= 0) {
|
if (fd >= 0) {
|
||||||
|
|
||||||
ck_write(fd, data, len, fn);
|
ck_write(fd, data, len, fn);
|
||||||
|
@ -989,7 +989,6 @@ int main(int argc, char **argv_orig, char **envp) {
|
|||||||
if (unlikely(afl->afl_env.afl_persistent_record)) {
|
if (unlikely(afl->afl_env.afl_persistent_record)) {
|
||||||
|
|
||||||
afl->fsrv.persistent_record = atoi(afl->afl_env.afl_persistent_record);
|
afl->fsrv.persistent_record = atoi(afl->afl_env.afl_persistent_record);
|
||||||
afl->fsrv.persistent_record_dir = alloc_printf("%s/crashes", afl->out_dir);
|
|
||||||
|
|
||||||
if (afl->fsrv.persistent_record < 2) {
|
if (afl->fsrv.persistent_record < 2) {
|
||||||
|
|
||||||
@ -1533,6 +1532,8 @@ int main(int argc, char **argv_orig, char **envp) {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
afl->fsrv.persistent_record_dir = alloc_printf("%s/crashes", afl->out_dir);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (afl->shmem_testcase_mode) { setup_testcase_shmem(afl); }
|
if (afl->shmem_testcase_mode) { setup_testcase_shmem(afl); }
|
||||||
|
Reference in New Issue
Block a user