From ea2f5c1309ce7f2d1613f54691f216a5b1be3b59 Mon Sep 17 00:00:00 2001 From: cuz Date: Mon, 19 Jun 2000 06:14:44 +0000 Subject: [PATCH] Fixed a bug git-svn-id: svn://svn.cc65.org/cc65/trunk@88 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- libsrc/common/vsprintf.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libsrc/common/vsprintf.c b/libsrc/common/vsprintf.c index bb97a88ab..8b5700b2b 100644 --- a/libsrc/common/vsprintf.c +++ b/libsrc/common/vsprintf.c @@ -37,6 +37,9 @@ int vsprintf (char* buf, char* format, va_list ap) /* Do formatting and output */ _printf (&d, format, ap); + /* Terminate the result string */ + buf [d.ccount++] = '\0'; + /* Return bytes written */ return d.ccount; } -- 2.39.5