aboutsummaryrefslogtreecommitdiff
path: root/include/error_handler.h
diff options
context:
space:
mode:
authorJoseph Hunkeler <jhunkeler@gmail.com>2020-05-25 23:54:52 -0400
committerJoseph Hunkeler <jhunkeler@gmail.com>2020-05-25 23:54:52 -0400
commit5cce499107951ca06574b7dde6ff2bb6e25370c3 (patch)
tree31681b4edd3b3fb8d79da686f2596a957f0f3a7a /include/error_handler.h
parentbb88ad38aacb40a9a3debcdcbeb21fef2e537dcd (diff)
downloadspmc-5cce499107951ca06574b7dde6ff2bb6e25370c3.tar.gz
Error handler:
* Add spm_die() * Add SPM_ERR_FETCH to handle non-package download failures
Diffstat (limited to 'include/error_handler.h')
-rw-r--r--include/error_handler.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/error_handler.h b/include/error_handler.h
index eaf6420..5e1639b 100644
--- a/include/error_handler.h
+++ b/include/error_handler.h
@@ -18,6 +18,7 @@
#define SPM_ERR_MANIFEST_EMPTY _SPM_ERR(8) // manifest file has no data
#define SPM_ERR_PARSE _SPM_ERR(9) // general parsing error
#define SPM_ERR_NOT_IMPLEMENTED _SPM_ERR(10) // not implemented (does exist on this platform)
+#define SPM_ERR_FETCH _SPM_ERR(11) // failed to download data (non-package)
extern int spmerrno;
extern const char *SPM_ERR_STRING[];
@@ -25,5 +26,6 @@ extern const char *SPM_ERR_STRING[];
void spmerrno_cause(const char *reason);
char *spm_strerror(int code);
void spm_perror(const char *msg);
+void spm_die(void);
#endif //SPM_ERROR_HANDLER_H