summaryrefslogtreecommitdiff
path: root/source3/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source3/lib')
-rw-r--r--source3/lib/slprintf.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source3/lib/slprintf.c b/source3/lib/slprintf.c
index 1d18055643..4de7b10f4f 100644
--- a/source3/lib/slprintf.c
+++ b/source3/lib/slprintf.c
@@ -61,7 +61,8 @@ int vslprintf(char *str, int n, char *format, va_list ap)
}
}
- ret = vsprintf(buf, format, ap);
+ vsprintf(buf, format, ap);
+ ret = strlen(buf);
if (ret < 0) {
str[0] = 0;