helly           Sun Aug 14 17:04:55 2005 EDT

  Modified files:              
    /php-src/main       spprintf.c 
  Log:
  - Need to terminate [v]uspprintf() with two \0
  
http://cvs.php.net/diff.php/php-src/main/spprintf.c?r1=1.29&r2=1.30&ty=u
Index: php-src/main/spprintf.c
diff -u php-src/main/spprintf.c:1.29 php-src/main/spprintf.c:1.30
--- php-src/main/spprintf.c:1.29        Sun Aug 14 16:12:51 2005
+++ php-src/main/spprintf.c     Sun Aug 14 17:04:52 2005
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: spprintf.c,v 1.29 2005/08/14 20:12:51 helly Exp $ */
+/* $Id: spprintf.c,v 1.30 2005/08/14 21:04:52 helly Exp $ */
 
 /* This is the spprintf implementation.
  * It has emerged from apache snprintf. See original header:
@@ -847,6 +847,7 @@
        if (max_len && xbuf.len > max_len) {
                xbuf.len = max_len;
        }
+       smart_str_appendc(&xbuf, '\0'); /* we need \0\0 as termination */
        smart_str_0(&xbuf);
                
        *pbuf = xbuf.c;

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to