Given how often a panic has to do with malloc() problems, don't tempt
authorAndrew Bartlett <abartlet@samba.org>
Sun, 21 Mar 2004 08:43:41 +0000 (08:43 +0000)
committerAndrew Bartlett <abartlet@samba.org>
Sun, 21 Mar 2004 08:43:41 +0000 (08:43 +0000)
things more by calling SAFE_FREE() just before we exit our panic handler.

Andrew Bartlett

source/lib/util.c

index 10d224baabfb73a9b5d1cfa4430b330642b7437d..3f57048a00b2629ab9e7afef6eb6da0256b976f9 100644 (file)
@@ -1411,7 +1411,7 @@ void smb_panic2(const char *why, BOOL decrement_pid_count )
                for (i = 0; i < backtrace_size; i++)
                        DEBUGADD(0, (" #%u %s\n", i, backtrace_strings[i]));
 
-               SAFE_FREE(backtrace_strings);
+               /* Leak the backtrace_strings, rather than risk what free() might do */
        }
 
 #elif HAVE_LIBEXC