summaryrefslogtreecommitdiffstats
path: root/src/util
diff options
context:
space:
mode:
Diffstat (limited to 'src/util')
-rw-r--r--src/util/testpkg.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/util/testpkg.c b/src/util/testpkg.c
index 66569f1e..1ad1d14b 100644
--- a/src/util/testpkg.c
+++ b/src/util/testpkg.c
@@ -23,20 +23,21 @@
#include <stdio.h>
#include <stdlib.h>
+#include <stdarg.h>
#include <string.h>
#include <libgen.h>
#include <alpm.h>
-void output_cb(pmloglevel_t level, char *msg)
+void output_cb(pmloglevel_t level, char *fmt, va_list args)
{
- if(strlen(msg)) {
+ if(strlen(fmt)) {
switch(level) {
case PM_LOG_ERROR: printf("error: "); break;
case PM_LOG_WARNING: printf("warning: "); break;
default: break;
}
- puts(msg);
+ vprintf(fmt, args);
}
}