allocate space for NUL

This commit is contained in:
Sascha Schumann 2002-04-20 18:58:20 +00:00
parent 6075a65319
commit 5e25c15d6c

View File

@ -188,7 +188,7 @@ PHP_FUNCTION(dio_read)
RETURN_NULL();
}
data = erealloc(data, res);
data = erealloc(data, res + 1);
data[res] = 0;
RETURN_STRINGL(data, res, 0);