samba-cvs.cvs
[Top] [All Lists]

svn commit: samba r13400 - in branches/SAMBA_4_0/source/lib/talloc: .

Subject: svn commit: samba r13400 - in branches/SAMBA_4_0/source/lib/talloc: .
From:
Date: Thu, 9 Feb 2006 00:49:04 +0000 GMT
Author: jpeach
Date: 2006-02-09 00:49:03 +0000 (Thu, 09 Feb 2006)
New Revision: 13400

WebSVN: 
http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=13400

Log:
Only return NULL from talloc_asprintf if vsnprintf returns an
error (ie. zero is not an error).

Modified:
   branches/SAMBA_4_0/source/lib/talloc/talloc.c


Changeset:
Modified: branches/SAMBA_4_0/source/lib/talloc/talloc.c
===================================================================
--- branches/SAMBA_4_0/source/lib/talloc/talloc.c       2006-02-09 00:23:40 UTC 
(rev 13399)
+++ branches/SAMBA_4_0/source/lib/talloc/talloc.c       2006-02-09 00:49:03 UTC 
(rev 13400)
@@ -1011,7 +1011,7 @@
        
        VA_COPY(ap2, ap);
 
-       if ((len = vsnprintf(NULL, 0, fmt, ap2)) <= 0) {
+       if ((len = vsnprintf(NULL, 0, fmt, ap2)) < 0) {
                return NULL;
        }
 

<Prev in Thread] Current Thread [Next in Thread>
  • svn commit: samba r13400 - in branches/SAMBA_4_0/source/lib/talloc: ., jpeach <=