diff options
author | oharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2008-03-10 12:04:30 +0000 |
---|---|---|
committer | oharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2008-03-10 12:04:30 +0000 |
commit | 0a34980f2bfb403ce56d6407ffa7891890852dbb (patch) | |
tree | 21035e2aaa21f68ab6840897ae4362bce3e5efad /src | |
parent | ecb227f10cab328e264cf9a828f508fa395ade8c (diff) | |
download | openocd+libswd-0a34980f2bfb403ce56d6407ffa7891890852dbb.tar.gz openocd+libswd-0a34980f2bfb403ce56d6407ffa7891890852dbb.tar.bz2 openocd+libswd-0a34980f2bfb403ce56d6407ffa7891890852dbb.tar.xz openocd+libswd-0a34980f2bfb403ce56d6407ffa7891890852dbb.zip |
- LOG_SILENT can be used to silence the log(needed in upcoming patches)
- ERROR_FAIL - added to emphasize that information about what went wrong is
contained in Error: log statements and not in a 32 bit return value.
git-svn-id: svn://svn.berlios.de/openocd/trunk@481 b42882b7-edfa-0310-969c-e2dbd0fdcd60
Diffstat (limited to 'src')
-rw-r--r-- | src/helper/log.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/helper/log.h b/src/helper/log.h index f7d70394..601b7527 100644 --- a/src/helper/log.h +++ b/src/helper/log.h @@ -26,6 +26,8 @@ #include <stdarg.h> /* logging priorities + * LOG_SILENT - turn off all output. In lieu of try+catch this can be used as a + * feeble ersatz. * LOG_USER - user messages. Could be anything from information * to progress messags. These messages do not represent * incorrect or unexpected behaviour, just normal execution. @@ -36,6 +38,7 @@ */ enum log_levels { + LOG_SILENT = -3, LOG_OUTPUT = -2, LOG_USER = -1, LOG_ERROR = 0, @@ -108,5 +111,9 @@ extern int debug_level; #define ERROR_INVALID_ARGUMENTS (-1) #define ERROR_NO_CONFIG_FILE (-2) #define ERROR_BUF_TOO_SMALL (-3) +/* see "Error:" message for meaningful message to the user. The caller should + * make no assumptions about what went wrong and try to handle the problem. + */ +#define ERROR_FAIL (-4) #endif /* LOG_H */ |