Skip to content

Commit

Permalink
Fixed linux build
Browse files Browse the repository at this point in the history
  • Loading branch information
drowaudio committed May 23, 2024
1 parent c08016d commit 937de9d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Dynamic library to catch run-time safety violations heavily inspired by [RADSan]
- [x] calloc ✔
- [x] realloc ✔
- [x] free ✔
- [x] reallocf ✔
- [x] reallocf (macOS)
- [x] valloc ✔
- [x] posix_memalign ✔
- [x] mmap ✔
Expand Down
2 changes: 2 additions & 0 deletions src/lib_rt_check.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,13 +57,15 @@ INTERCEPTOR(void*, realloc, void *ptr, size_t new_size)
return REAL(realloc)(ptr, new_size);
}

#if __APPLE__
INTERCEPTOR(void *, reallocf, void *ptr, size_t size)
{
log_function_if_realtime_context (__func__);

INTERCEPT_FUNCTION(void*, reallocf, void*, size_t);
return REAL(reallocf)(ptr, size);
}
#endif

INTERCEPTOR(void*, valloc, size_t size)
{
Expand Down

0 comments on commit 937de9d

Please sign in to comment.