- sprintf(string, " -R %d", CLAMP(asset->vmpeg_pframe_distance, 0, 2));
- strcat(mjpeg_command, string);
+ snprintf(string, sizeof(string),
+ " -R %d", CLAMP(asset->vmpeg_pframe_distance, 0, 2));
+ strncat(mjpeg_command, string, sizeof(mjpeg_command));