[fix] make sure that there is space in a string for \0 at the end