Blame jemalloc/include/jemalloc/internal/test_hooks.h

Packit 345191
#ifndef JEMALLOC_INTERNAL_TEST_HOOKS_H
Packit 345191
#define JEMALLOC_INTERNAL_TEST_HOOKS_H
Packit 345191
Packit 345191
extern JEMALLOC_EXPORT void (*test_hooks_arena_new_hook)();
Packit 345191
extern JEMALLOC_EXPORT void (*test_hooks_libc_hook)();
Packit 345191
Packit 345191
#define JEMALLOC_HOOK(fn, hook) ((void)(hook != NULL && (hook(), 0)), fn)
Packit 345191
Packit 345191
#define open JEMALLOC_HOOK(open, test_hooks_libc_hook)
Packit 345191
#define read JEMALLOC_HOOK(read, test_hooks_libc_hook)
Packit 345191
#define write JEMALLOC_HOOK(write, test_hooks_libc_hook)
Packit 345191
#define readlink JEMALLOC_HOOK(readlink, test_hooks_libc_hook)
Packit 345191
#define close JEMALLOC_HOOK(close, test_hooks_libc_hook)
Packit 345191
#define creat JEMALLOC_HOOK(creat, test_hooks_libc_hook)
Packit 345191
#define secure_getenv JEMALLOC_HOOK(secure_getenv, test_hooks_libc_hook)
Packit 345191
/* Note that this is undef'd and re-define'd in src/prof.c. */
Packit 345191
#define _Unwind_Backtrace JEMALLOC_HOOK(_Unwind_Backtrace, test_hooks_libc_hook)
Packit 345191
Packit 345191
#endif /* JEMALLOC_INTERNAL_TEST_HOOKS_H */