diff options
author | van Hauser <vh@thc.org> | 2020-04-26 01:25:39 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-26 01:25:39 +0200 |
commit | fb89b042f878e450f719d3303a6c4f777dbae0b1 (patch) | |
tree | 4ca27636df0f57b7b1cd2f9d92b4f243fd0c2ea8 | |
parent | 646aeb2b18f91c562fa8de656c87f3cb205ce99f (diff) | |
parent | 80916a3613c05b651eaab005caeb96bd80664d0f (diff) | |
download | afl++-fb89b042f878e450f719d3303a6c4f777dbae0b1.tar.gz |
Merge pull request #337 from devnexen/android_support_arc4_api
Android supports arc4 api.
-rw-r--r-- | include/types.h | 4 | ||||
-rw-r--r-- | libdislocator/libdislocator.so.c | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/include/types.h b/include/types.h index f2a12953..a204294f 100644 --- a/include/types.h +++ b/include/types.h @@ -108,7 +108,7 @@ typedef int64_t s64; }) #ifdef AFL_LLVM_PASS -#if defined(__linux__) +#if defined(__linux__) || !defined(__ANDROID__) #define AFL_SR(s) (srandom(s)) #define AFL_R(x) (random() % (x)) #else @@ -116,7 +116,7 @@ typedef int64_t s64; #define AFL_R(x) (arc4random_uniform(x)) #endif #else -#if defined(__linux__) +#if defined(__linux__) || !defined(__ANDROID__) #define SR(s) (srandom(s)) #define R(x) (random() % (x)) #else diff --git a/libdislocator/libdislocator.so.c b/libdislocator/libdislocator.so.c index 6c8916d6..73ddc292 100644 --- a/libdislocator/libdislocator.so.c +++ b/libdislocator/libdislocator.so.c @@ -37,7 +37,7 @@ #include <sys/param.h> #endif -#ifdef __linux__ +#if defined(__linux__) && !defined(__ANDROID__) #include <unistd.h> #include <sys/syscall.h> #ifdef __NR_getrandom |