summaryrefslogtreecommitdiff
path: root/error.h
diff options
context:
space:
mode:
Diffstat (limited to 'error.h')
-rw-r--r--error.h17
1 files changed, 13 insertions, 4 deletions
diff --git a/error.h b/error.h
index b70085f..f0a67a5 100644
--- a/error.h
+++ b/error.h
@@ -7,11 +7,20 @@ typedef unsigned int ErrCode;
#define NOERR 0
#define ERR_NON_FATAL 110
#define ERR_FATAL 120
-#define ERR_CFG_NON_FATAL 210
-#define ERR_CFG_FATAL 220
-
+#define CFG_ERR_NON_FATAL 210
+#define CFG_ERR_KEYBIND 211
+#define CFG_ERR_FATAL 220
+#define CMD_ERR_NON_FATAL 310
+#define CMD_ERR_NOT_FOUND 311
+#define CMD_ERR_WRONG_ARGS 312
+#define CMD_ERR_FATAL 320
struct Err
{
ErrCode code;
- std::string errorMessage;
+ std::string message;
+ Err(ErrCode code, std::string message)
+ {
+ this->code = code;
+ this->message = message;
+ }
};