Fix vprintf(3)

TODO: what did this actually fix?
This commit is contained in:
Xavier Del Campo Romero 2021-10-24 03:02:02 +02:00
parent a34280dec7
commit 573e4c150b

View File

@ -811,9 +811,9 @@ static int __vsnprintf_internal(char *string, size_t size, const char *fmt, va_l
static int vsnprintf_put_in_string(char *string, unsigned int sz, char c, int pos)
{
if(pos>=sz)
if(pos >= sz && c)
return 0;
else
else if (c || pos <= sz)
string[pos] = c;
return 1;