Fix snprintf() usage