|
From: Dan M. <da...@su...> - 2009-02-16 20:29:33
|
A good set of tests to run for memory corruption checking on Solaris is: (using sh & derivatives) LD_PRELOAD=libumem.so UMEM_DEBUG=default <command> (using csh & derivatives) (setenv LD_PRELOAD libumem.so; setenv UMEM_DEBUG default ; <command>) If libumem (user-space version of the Solaris kmem) detects corruption, it'll core-dump your app and you can look at it with mdb post-mortem to see what's up. This includes the "::findleaks" dcmd, which does exactly what you think it does. Take a core dump on a running (with libumem) racoon or setkey with gcore and then run ::findleaks. Since you're working on the port, you might as well exploit your target's toolset. Dan |