diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2006-02-28 13:12:39 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:52:09 -0500 |
commit | aa04388943fe5d7d8c873a6ee8a4cc9af2491532 (patch) | |
tree | 8073b268875c22e8e0785ddffef42fcf3af3dac1 /source4/lib/util/fault.c | |
parent | 4d3cc7384338fe2182a2029c2e6d2fcca2ec8813 (diff) | |
download | samba-aa04388943fe5d7d8c873a6ee8a4cc9af2491532.tar.gz samba-aa04388943fe5d7d8c873a6ee8a4cc9af2491532.tar.bz2 samba-aa04388943fe5d7d8c873a6ee8a4cc9af2491532.zip |
r13752: Add doxyfile and fix formatting of comments. Current output is available at http://samba.org/~jelmer/util-api/
(This used to be commit 90812203df151a5e62394306827c72adfe13c63c)
Diffstat (limited to 'source4/lib/util/fault.c')
-rw-r--r-- | source4/lib/util/fault.c | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/source4/lib/util/fault.c b/source4/lib/util/fault.c index 3670575dcc..abe3f141ce 100644 --- a/source4/lib/util/fault.c +++ b/source4/lib/util/fault.c @@ -23,6 +23,11 @@ #include "system/wait.h" #include "system/filesys.h" +/** + * @file + * @brief Fault handling + */ + /* the registered fault handler */ static struct { const char *name; @@ -38,6 +43,9 @@ static const char *progname; #include <libexc.h> #endif +/** + * Write backtrace to debug log + */ void call_backtrace(void) { #ifdef HAVE_BACKTRACE @@ -101,9 +109,9 @@ void call_backtrace(void) #endif } -/******************************************************************* +/** Something really nasty happened - panic ! -********************************************************************/ +**/ void smb_panic(const char *why) { const char *cmd = lp_panic_action(); @@ -138,9 +146,9 @@ void smb_panic(const char *why) abort(); } -/******************************************************************* +/** report a fault -********************************************************************/ +**/ static void fault_report(int sig) { static int counter; @@ -157,9 +165,9 @@ static void fault_report(int sig) exit(1); } -/**************************************************************************** +/** catch serious errors -****************************************************************************/ +**/ static void sig_fault(int sig) { if (fault_handlers.fault_handler) { @@ -170,9 +178,9 @@ static void sig_fault(int sig) fault_report(sig); } -/******************************************************************* +/** setup our fault handlers -********************************************************************/ +**/ void fault_setup(const char *pname) { if (progname == NULL) { @@ -192,7 +200,7 @@ void fault_setup(const char *pname) #endif } -/* +/** register a fault handler. Should only be called once in the execution of smbd. */ |