summaryrefslogtreecommitdiff
path: root/source4/lib/util/fault.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/lib/util/fault.c')
-rw-r--r--source4/lib/util/fault.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/source4/lib/util/fault.c b/source4/lib/util/fault.c
index ff44b8a292..8b447851dc 100644
--- a/source4/lib/util/fault.c
+++ b/source4/lib/util/fault.c
@@ -109,18 +109,19 @@ _PUBLIC_ void call_backtrace(void)
#endif
}
+_PUBLIC_ const char *panic_action = NULL;
+
/**
Something really nasty happened - panic !
**/
_PUBLIC_ void smb_panic(const char *why)
{
- const char *cmd = lp_panic_action();
int result;
- if (cmd && *cmd) {
+ if (panic_action && *panic_action) {
char pidstr[20];
char cmdstring[200];
- safe_strcpy(cmdstring, cmd, sizeof(cmdstring));
+ safe_strcpy(cmdstring, panic_action, sizeof(cmdstring));
snprintf(pidstr, sizeof(pidstr), "%u", getpid());
all_string_sub(cmdstring, "%PID%", pidstr, sizeof(cmdstring));
if (progname) {