diff options
author | van Hauser <vh@thc.org> | 2020-11-08 17:11:57 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-08 17:11:57 +0100 |
commit | 4c59c5234aec0469e4dd02561dbd84387bd53155 (patch) | |
tree | 12d8cc15ab552e900943251d513f5680f7d1d629 /src/afl-cc.c | |
parent | 3b799c09cd68bb68b26784261f1fbaa3e737c747 (diff) | |
parent | 82d1c3e18dd1b90fa15f7c056f94dc1a06ee345d (diff) | |
download | afl++-4c59c5234aec0469e4dd02561dbd84387bd53155.tar.gz |
Merge pull request #598 from AFLplusplus/dev
fix afl-cc bug for llvm 10.0.0
Diffstat (limited to 'src/afl-cc.c')
-rw-r--r-- | src/afl-cc.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/afl-cc.c b/src/afl-cc.c index 46468dda..771a58f5 100644 --- a/src/afl-cc.c +++ b/src/afl-cc.c @@ -38,6 +38,12 @@ #if !defined(LLVM_MAJOR) #define LLVM_MAJOR 0 #endif +#if (LLVM_MINOR - 0 == 0) + #undef LLVM_MINOR +#endif +#if !defined(LLVM_MINOR) + #define LLVM_MINOR 0 +#endif static u8 * obj_path; /* Path to runtime libraries */ static u8 **cc_params; /* Parameters passed to the real CC */ @@ -501,7 +507,7 @@ static void edit_params(u32 argc, char **argv, char **envp) { if (instrument_mode == INSTRUMENT_PCGUARD) { -#if LLVM_MAJOR >= 10 || (LLVM_MAJOR == 10 && LLVM_MINOR > 0) +#if LLVM_MAJOR > 10 || (LLVM_MAJOR == 10 && LLVM_MINOR > 0) cc_params[cc_par_cnt++] = "-Xclang"; cc_params[cc_par_cnt++] = "-load"; cc_params[cc_par_cnt++] = "-Xclang"; |