code format

This commit is contained in:
Dominik Maier
2020-06-15 11:08:24 +02:00
parent acb0a2f027
commit dc002b4b35
8 changed files with 15 additions and 17 deletions

View File

@ -36,7 +36,7 @@
#include <sys/mman.h> #include <sys/mman.h>
#ifndef USEMMAP #ifndef USEMMAP
#include <sys/shm.h> #include <sys/shm.h>
#endif #endif
#include <sys/wait.h> #include <sys/wait.h>
#include <sys/types.h> #include <sys/types.h>

View File

@ -67,7 +67,7 @@
#include <sys/wait.h> #include <sys/wait.h>
#include <sys/time.h> #include <sys/time.h>
#ifndef USEMMAP #ifndef USEMMAP
#include <sys/shm.h> #include <sys/shm.h>
#endif #endif
#include <sys/stat.h> #include <sys/stat.h>
#include <sys/types.h> #include <sys/types.h>

View File

@ -52,7 +52,7 @@
#include <sys/wait.h> #include <sys/wait.h>
#include <sys/time.h> #include <sys/time.h>
#ifndef USEMMAP #ifndef USEMMAP
#include <sys/shm.h> #include <sys/shm.h>
#endif #endif
#include <sys/stat.h> #include <sys/stat.h>
#include <sys/types.h> #include <sys/types.h>

View File

@ -124,11 +124,11 @@ void write_stats_file(afl_state_t *afl, double bitmap_cvg, double stability,
afl->last_hang_time / 1000, afl->fsrv.total_execs - afl->last_crash_execs, afl->last_hang_time / 1000, afl->fsrv.total_execs - afl->last_crash_execs,
afl->fsrv.exec_tmout, afl->slowest_exec_ms, afl->fsrv.exec_tmout, afl->slowest_exec_ms,
#ifndef __HAIKU__ #ifndef __HAIKU__
#ifdef __APPLE__ #ifdef __APPLE__
(unsigned long int)(rus.ru_maxrss >> 20), (unsigned long int)(rus.ru_maxrss >> 20),
#else #else
(unsigned long int)(rus.ru_maxrss >> 10), (unsigned long int)(rus.ru_maxrss >> 10),
#endif #endif
#else #else
-1UL, -1UL,
#endif #endif

View File

@ -36,13 +36,11 @@ static void at_exit() {
int i; int i;
char *ptr = getenv("__AFL_TARGET_PID1"); char *ptr = getenv("__AFL_TARGET_PID1");
if (ptr && *ptr && (i = atoi(ptr)) > 0) if (ptr && *ptr && (i = atoi(ptr)) > 0) kill(i, SIGKILL);
kill(i, SIGKILL);
ptr = getenv("__AFL_TARGET_PID2"); ptr = getenv("__AFL_TARGET_PID2");
if (ptr && *ptr && (i = atoi(ptr)) > 0) if (ptr && *ptr && (i = atoi(ptr)) > 0) kill(i, SIGKILL);
kill(i, SIGKILL);
// anything else? shared memory? // anything else? shared memory?

View File

@ -57,7 +57,7 @@
#include <sys/wait.h> #include <sys/wait.h>
#include <sys/time.h> #include <sys/time.h>
#ifndef USEMMAP #ifndef USEMMAP
#include <sys/shm.h> #include <sys/shm.h>
#endif #endif
#include <sys/stat.h> #include <sys/stat.h>
#include <sys/types.h> #include <sys/types.h>

View File

@ -55,7 +55,7 @@
#include <sys/wait.h> #include <sys/wait.h>
#include <sys/time.h> #include <sys/time.h>
#ifndef USEMMAP #ifndef USEMMAP
#include <sys/shm.h> #include <sys/shm.h>
#endif #endif
#include <sys/stat.h> #include <sys/stat.h>
#include <sys/types.h> #include <sys/types.h>