imv-scanner: Properly check snprintf() return value