summaryrefslogtreecommitdiff
path: root/source4/lib/replace/snprintf.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2008-03-19 10:18:35 +1100
committerAndrew Bartlett <abartlet@samba.org>2008-03-19 10:18:35 +1100
commitb1b37e3776c6e6e20f42140a907e296b65cc0c62 (patch)
tree601f049791bcbd9df9daef64b0b1003dbf1a413b /source4/lib/replace/snprintf.c
parent9e6b0c28712ee77ce878809c8576826a3ba08d95 (diff)
parent52669d84722c175555e17a222077f845d9aa958f (diff)
downloadsamba-b1b37e3776c6e6e20f42140a907e296b65cc0c62.tar.gz
samba-b1b37e3776c6e6e20f42140a907e296b65cc0c62.tar.bz2
samba-b1b37e3776c6e6e20f42140a907e296b65cc0c62.zip
Merge branch 'v4-0-test' of ssh://git.samba.org/data/git/samba into 4-0-local
(This used to be commit 400c16e7004bc3a881bb6efb99a273cdac87f70c)
Diffstat (limited to 'source4/lib/replace/snprintf.c')
-rw-r--r--source4/lib/replace/snprintf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source4/lib/replace/snprintf.c b/source4/lib/replace/snprintf.c
index 9f8a7657e5..a174dcffed 100644
--- a/source4/lib/replace/snprintf.c
+++ b/source4/lib/replace/snprintf.c
@@ -1264,7 +1264,7 @@ static int add_cnk_list_entry(struct pr_chunk_x **list,
VA_COPY(ap2, ap);
ret = vsnprintf(NULL, 0, format, ap2);
va_end(ap2);
- if (ret <= 0) return ret;
+ if (ret < 0) return ret;
(*ptr) = (char *)malloc(ret+1);
if (!*ptr) return -1;