diff options
author | Andrey Nazarov <skuller@skuller.net> | 2011-02-06 00:33:39 +0300 |
---|---|---|
committer | Andrey Nazarov <skuller@skuller.net> | 2011-02-06 17:32:57 +0300 |
commit | 6340c40d5fe0a500c84c2a7a5c0fb8a2f97c8a8d (patch) | |
tree | 9e4817aa42cfd1b00d0a0882438022125f172ea7 /src/common.h | |
parent | abdde4dc29aafb1eaa62046b45ab7f61a4e4840b (diff) |
Improve last error reporting.
Implement Com_SetLastError and Com_GetLastError functions. Save the last
error message passed to Com_LPrintf. Limit maximum error message size to
1024 chars.
Diffstat (limited to 'src/common.h')
-rw-r--r-- | src/common.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/common.h b/src/common.h index db4a06b..00df578 100644 --- a/src/common.h +++ b/src/common.h @@ -456,6 +456,7 @@ MISC */ #define MAXPRINTMSG 4096 +#define MAXERRORMSG 1024 typedef enum { COLOR_BLACK, @@ -505,6 +506,9 @@ void Com_EndRedirect (void); void Com_AbortFrame( void ); #endif +char *Com_GetLastError( void ); +void Com_SetLastError( const char *msg ); + void Com_Quit( const char *reason, killtype_t type ) q_noreturn; void Com_SetColor( color_index_t color ); |