Zeroing the buffer

The previous behavior was just to mark the size as zero, but it was
found that is better to add a '\0' at the beginning to make this
clearer.