mirror of
https://github.com/AFLplusplus/AFLplusplus.git
synced 2025-06-12 10:08:07 +00:00
fix instrumentation for -Werror,-Wunused-but-set-variable
`used` is so it isn't optimized out. `unused` is to avoid the warning.
This commit is contained in:
@ -1035,7 +1035,7 @@ static void edit_params(u32 argc, char **argv, char **envp) {
|
|||||||
|
|
||||||
cc_params[cc_par_cnt++] =
|
cc_params[cc_par_cnt++] =
|
||||||
"-D__AFL_LOOP(_A)="
|
"-D__AFL_LOOP(_A)="
|
||||||
"({ static volatile char *_B __attribute__((used)); "
|
"({ static volatile char *_B __attribute__((used,unused)); "
|
||||||
" _B = (char*)\"" PERSIST_SIG
|
" _B = (char*)\"" PERSIST_SIG
|
||||||
"\"; "
|
"\"; "
|
||||||
#ifdef __APPLE__
|
#ifdef __APPLE__
|
||||||
@ -1049,7 +1049,7 @@ static void edit_params(u32 argc, char **argv, char **envp) {
|
|||||||
|
|
||||||
cc_params[cc_par_cnt++] =
|
cc_params[cc_par_cnt++] =
|
||||||
"-D__AFL_INIT()="
|
"-D__AFL_INIT()="
|
||||||
"do { static volatile char *_A __attribute__((used)); "
|
"do { static volatile char *_A __attribute__((used,unused)); "
|
||||||
" _A = (char*)\"" DEFER_SIG
|
" _A = (char*)\"" DEFER_SIG
|
||||||
"\"; "
|
"\"; "
|
||||||
#ifdef __APPLE__
|
#ifdef __APPLE__
|
||||||
|
Reference in New Issue
Block a user