00001 /************************************************************ 00002 00003 Copyright 1998 by Thomas E. Dickey <dickey@clark.net> 00004 00005 All Rights Reserved 00006 00007 Permission is hereby granted, free of charge, to any person obtaining a 00008 copy of this software and associated documentation files (the 00009 "Software"), to deal in the Software without restriction, including 00010 without limitation the rights to use, copy, modify, merge, publish, 00011 distribute, sublicense, and/or sell copies of the Software, and to 00012 permit persons to whom the Software is furnished to do so, subject to 00013 the following conditions: 00014 00015 The above copyright notice and this permission notice shall be included 00016 in all copies or substantial portions of the Software. 00017 00018 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 00019 OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 00020 MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 00021 IN NO EVENT SHALL THE ABOVE LISTED COPYRIGHT HOLDER(S) BE LIABLE FOR ANY 00022 CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 00023 TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 00024 SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 00025 00026 Except as contained in this notice, the name(s) of the above copyright 00027 holders shall not be used in advertising or otherwise to promote the 00028 sale, use or other dealings in this Software without prior written 00029 authorization. 00030 00031 ********************************************************/ 00032 00033 00034 #ifndef _DM_ERROR_H_ 00035 #define _DM_ERROR_H_ 1 00036 00037 #include "greet.h" 00038 00039 #include <stdarg.h> 00040 00041 void GDebug( const char *fmt, ... ); 00042 void Debug( const char *fmt, ... ); 00043 void LogInfo( const char *fmt, ... ); 00044 void LogWarn( const char *fmt, ... ); 00045 void LogError( const char *fmt, ... ); 00046 void LogPanic( const char *fmt, ... ) ATTR_NORETURN; 00047 void LogOutOfMem( void ); 00048 void Panic( const char *mesg ) ATTR_NORETURN; 00049 void InitErrorLog( const char *errorLogFile ); 00050 #ifdef USE_SYSLOG 00051 void ReInitErrorLog( void ); 00052 #else 00053 # define ReInitErrorLog() while(0) 00054 #endif 00055 int ASPrintf( char **strp, const char *fmt, ... ); 00056 int VASPrintf( char **strp, const char *fmt, va_list args ); 00057 00058 #endif /* _DM_ERROR_H_ */
1.6.1