Planeshift
pserror.h
Go to the documentation of this file.
1 /* We have to find a better solution later (ie exceptions?)
2  * just implement errorhalt (which should stop the program)
3  * and errormsg (which should just print an error msg and continue
4  */
5 
6 #ifndef __ERROR_H__
7 #define __ERROR_H__
8 
13 void psprintf(const char *arg, ...);
14 
15 void errorhalt(const char* function, const char* file, int line,
16  const char *msg);
17 void errormsg(const char* function, const char* file, int line,
18  const char *msg);
19 
20 #define ERRORHALT(msg) errorhalt (__PRETTY_FUNCTION__,__FILE__, __LINE__, msg)
21 #define ERRORMSG(msg) errormsg (__PRETTY_FUNCTION__,__FILE__, __LINE__, msg)
22 
25 #endif
void errormsg(const char *function, const char *file, int line, const char *msg)
void errorhalt(const char *function, const char *file, int line, const char *msg)
void psprintf(const char *arg,...)