summaryrefslogtreecommitdiff
path: root/lib/libalpm/util.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libalpm/util.h')
-rw-r--r--lib/libalpm/util.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/libalpm/util.h b/lib/libalpm/util.h
index 0bf122cd..74b4f981 100644
--- a/lib/libalpm/util.h
+++ b/lib/libalpm/util.h
@@ -51,6 +51,10 @@
#define ASSERT(cond, action) do { if(!(cond)) { action; } } while(0)
+#define RET_ERR(err, ret) do { pm_errno = (err); \
+ _alpm_log(PM_LOG_DEBUG, "returning error %d from %s : %s\n", err, __func__, alpm_strerrorlast()); \
+ return(ret); } while(0)
+
int _alpm_makepath(const char *path);
int _alpm_makepath_mode(const char *path, mode_t mode);
int _alpm_copyfile(const char *src, const char *dest);