diff options
Diffstat (limited to 'libc')
| -rw-r--r-- | libc/stdio/printf.c | 1 | 
1 files changed, 1 insertions, 0 deletions
diff --git a/libc/stdio/printf.c b/libc/stdio/printf.c index 92b5b5956..e311a4f87 100644 --- a/libc/stdio/printf.c +++ b/libc/stdio/printf.c @@ -1451,6 +1451,7 @@ int vasprintf(char **__restrict buf, const char * __restrict format,  		return -1;  	}  	rv = vfprintf(f, format, arg); +	if (rv >= 0) fputc('\0', f);  	fclose(f);  	if (rv < 0) {  		free(*buf);  | 
