summaryrefslogtreecommitdiff
path: root/src/common.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/common.h')
-rw-r--r--src/common.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/common.h b/src/common.h
index e1e7f0035..5986a6568 100644
--- a/src/common.h
+++ b/src/common.h
@@ -46,8 +46,13 @@ typedef SSIZE_T ssize_t;
#include "thread-utils.h"
#include "bswap.h"
-extern int git__throw(int error, const char *, ...) GIT_FORMAT_PRINTF(2, 3);
-extern int git__rethrow(int error, const char *, ...) GIT_FORMAT_PRINTF(2, 3);
+extern void git___throw(const char *, ...) GIT_FORMAT_PRINTF(1, 2);
+#define git__throw(error, ...) \
+ (git___throw(__VA_ARGS__), error)
+
+extern void git___rethrow(const char *, ...) GIT_FORMAT_PRINTF(1, 2);
+#define git__rethrow(error, ...) \
+ (git___rethrow(__VA_ARGS__), error)
#include "util.h"