From 80afbe5cf5f30e0f3116f99fc44c930f2cd60935 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Tue, 28 Mar 2006 15:50:13 +0000 Subject: r14751: Use the noreturn attribute to try and tell coverity that smb_panic can't return. Jeremy. (This used to be commit ba9c98983efbf4871e1ec07df37590d97ec52fba) --- source3/lib/util.c | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) (limited to 'source3/lib/util.c') diff --git a/source3/lib/util.c b/source3/lib/util.c index 5bf9409c2f..0b831ea335 100644 --- a/source3/lib/util.c +++ b/source3/lib/util.c @@ -1541,14 +1541,6 @@ gid_t nametogid(const char *name) return (gid_t)-1; } -/******************************************************************* - legacy wrapper for smb_panic2() -********************************************************************/ -void smb_panic( const char *why ) -{ - smb_panic2( why, True ); -} - /******************************************************************* Something really nasty happened - panic ! ********************************************************************/ @@ -1557,7 +1549,7 @@ void smb_panic( const char *why ) #include #endif -void smb_panic2(const char *why, BOOL decrement_pid_count ) +static void smb_panic2(const char *why, BOOL decrement_pid_count ) { char *cmd; int result; @@ -1663,6 +1655,17 @@ void smb_panic2(const char *why, BOOL decrement_pid_count ) abort(); } +/******************************************************************* + wrapper for smb_panic2() +********************************************************************/ + + void smb_panic( const char *why ) +{ + smb_panic2( why, True ); + /* Notreached. */ + abort(); +} + /******************************************************************* A readdir wrapper which just returns the file name. ********************************************************************/ -- cgit