fixed issue with null terminating strings