diff options
author | van Hauser <vh@thc.org> | 2020-06-29 18:36:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-29 18:36:06 +0200 |
commit | fc5cfc6cb309b072a45b991be117c17396e46a89 (patch) | |
tree | 4c762f1e2cfb4a8741c08b5b60d07c2ae8eee860 /include/alloc-inl.h | |
parent | 76a2d9b59b23873c8a6d174a2f3c48eba60712fb (diff) | |
parent | 6d9b29daca46c8912aa9ddf6c053bc8554e9e9f7 (diff) | |
download | afl++-fc5cfc6cb309b072a45b991be117c17396e46a89.tar.gz |
Merge pull request #428 from AFLplusplus/dev
Dev
Diffstat (limited to 'include/alloc-inl.h')
-rw-r--r-- | include/alloc-inl.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/include/alloc-inl.h b/include/alloc-inl.h index ca593549..832b2de4 100644 --- a/include/alloc-inl.h +++ b/include/alloc-inl.h @@ -170,10 +170,10 @@ static inline u8 *DFL_ck_strdup(u8 *str) { size = strlen((char *)str) + 1; ALLOC_CHECK_SIZE(size); - ret = malloc(size); + ret = (u8 *)malloc(size); ALLOC_CHECK_RESULT(ret, size); - return memcpy(ret, str, size); + return (u8 *)memcpy(ret, str, size); } @@ -204,7 +204,7 @@ static inline u8 *DFL_ck_memdup_str(u8 *mem, u32 size) { if (!mem || !size) { return NULL; } ALLOC_CHECK_SIZE(size); - ret = malloc(size + 1); + ret = (u8 *)malloc(size + 1); ALLOC_CHECK_RESULT(ret, size); memcpy(ret, mem, size); |