summaryrefslogtreecommitdiff
path: root/source3/lib/fault.c
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2007-09-14 11:07:02 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:30:45 -0500
commitb6514d02ecbeaff68b8f625e07e9c16dda8fddcf (patch)
tree4bf4ba0396334e7f84a563adb8b2d0b517b3d164 /source3/lib/fault.c
parent6005c4e657299355add620232d7570d8d1633213 (diff)
downloadsamba-b6514d02ecbeaff68b8f625e07e9c16dda8fddcf.tar.gz
samba-b6514d02ecbeaff68b8f625e07e9c16dda8fddcf.tar.bz2
samba-b6514d02ecbeaff68b8f625e07e9c16dda8fddcf.zip
r25150: don't recursivly call call dump_core()
as currently seen in 'make test' localy and in the farm metze (This used to be commit f41efe01b5a22889f5b18916df9a2f924263e7f9)
Diffstat (limited to 'source3/lib/fault.c')
-rw-r--r--source3/lib/fault.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/source3/lib/fault.c b/source3/lib/fault.c
index 3ddb88edc7..6ab1a07900 100644
--- a/source3/lib/fault.c
+++ b/source3/lib/fault.c
@@ -150,6 +150,14 @@ void dump_core_setup(const char *progname)
void dump_core(void)
{
+ static bool called;
+
+ if (called) {
+ DEBUG(0, ("dump_core() called recursive\n"));
+ exit(1);
+ }
+ called = true;
+
/* Note that even if core dumping has been disabled, we still set up
* the core path. This is to handle the case where core dumping is
* turned on in smb.conf and the relevant daemon is not restarted.