]> git.ipfire.org Git - thirdparty/strongswan.git/commit - src/libstrongswan/utils/leak_detective.c
leak-detective: override malloc functions instead of using deprecated hooks
authorMartin Willi <martin@revosec.ch>
Tue, 2 Apr 2013 11:37:06 +0000 (13:37 +0200)
committerMartin Willi <martin@revosec.ch>
Mon, 6 May 2013 13:15:24 +0000 (15:15 +0200)
commit17211b6b9ae3330c97691dd63ce0d54705de85b3
treeca4f828caaa3b42457298f5df39e03795fb9cb48
parente9b3bd54346d78343f74878c799dd11fd2e2276a
leak-detective: override malloc functions instead of using deprecated hooks

malloc hooks have become deprecated, and their use has always been problematic,
especially in multi-threaded applications. Replace the functionality by
overriding all malloc functions and query the system allocator functions
using dlsym() with RTLD_NEXT.
src/libstrongswan/utils/leak_detective.c