Flawfinder version 2.0.10, (C) 2001-2019 David A. Wheeler.
Number of rules (primarily dangerous function names) in C/C++ ruleset: 223
Examining data/nageru-2.0.1/futatabi/chroma_subsampler.cpp
Examining data/nageru-2.0.1/futatabi/chroma_subsampler.h
Examining data/nageru-2.0.1/futatabi/clip_list.cpp
Examining data/nageru-2.0.1/futatabi/clip_list.h
Examining data/nageru-2.0.1/futatabi/db.cpp
Examining data/nageru-2.0.1/futatabi/db.h
Examining data/nageru-2.0.1/futatabi/defs.h
Examining data/nageru-2.0.1/futatabi/embedded_files.h
Examining data/nageru-2.0.1/futatabi/eval.cpp
Examining data/nageru-2.0.1/futatabi/exif_parser.cpp
Examining data/nageru-2.0.1/futatabi/exif_parser.h
Examining data/nageru-2.0.1/futatabi/export.cpp
Examining data/nageru-2.0.1/futatabi/export.h
Examining data/nageru-2.0.1/futatabi/flags.cpp
Examining data/nageru-2.0.1/futatabi/flags.h
Examining data/nageru-2.0.1/futatabi/flow.cpp
Examining data/nageru-2.0.1/futatabi/flow.h
Examining data/nageru-2.0.1/futatabi/flow_main.cpp
Examining data/nageru-2.0.1/futatabi/frame_on_disk.cpp
Examining data/nageru-2.0.1/futatabi/frame_on_disk.h
Examining data/nageru-2.0.1/futatabi/gpu_timers.cpp
Examining data/nageru-2.0.1/futatabi/gpu_timers.h
Examining data/nageru-2.0.1/futatabi/jpeg_destroyer.h
Examining data/nageru-2.0.1/futatabi/jpeg_frame.h
Examining data/nageru-2.0.1/futatabi/jpeg_frame_view.cpp
Examining data/nageru-2.0.1/futatabi/jpeg_frame_view.h
Examining data/nageru-2.0.1/futatabi/jpeglib_error_wrapper.h
Examining data/nageru-2.0.1/futatabi/main.cpp
Examining data/nageru-2.0.1/futatabi/mainwindow.cpp
Examining data/nageru-2.0.1/futatabi/mainwindow.h
Examining data/nageru-2.0.1/futatabi/midi_mapper.cpp
Examining data/nageru-2.0.1/futatabi/midi_mapper.h
Examining data/nageru-2.0.1/futatabi/midi_mapping_dialog.cpp
Examining data/nageru-2.0.1/futatabi/midi_mapping_dialog.h
Examining data/nageru-2.0.1/futatabi/pbo_pool.cpp
Examining data/nageru-2.0.1/futatabi/pbo_pool.h
Examining data/nageru-2.0.1/futatabi/player.cpp
Examining data/nageru-2.0.1/futatabi/player.h
Examining data/nageru-2.0.1/futatabi/queue_spot_holder.h
Examining data/nageru-2.0.1/futatabi/util.cpp
Examining data/nageru-2.0.1/futatabi/util.h
Examining data/nageru-2.0.1/futatabi/vaapi_jpeg_decoder.cpp
Examining data/nageru-2.0.1/futatabi/vaapi_jpeg_decoder.h
Examining data/nageru-2.0.1/futatabi/video_stream.cpp
Examining data/nageru-2.0.1/futatabi/video_stream.h
Examining data/nageru-2.0.1/futatabi/vis.cpp
Examining data/nageru-2.0.1/futatabi/ycbcr_converter.cpp
Examining data/nageru-2.0.1/futatabi/ycbcr_converter.h
Examining data/nageru-2.0.1/nageru/alsa_input.cpp
Examining data/nageru-2.0.1/nageru/alsa_input.h
Examining data/nageru-2.0.1/nageru/alsa_output.cpp
Examining data/nageru-2.0.1/nageru/alsa_output.h
Examining data/nageru-2.0.1/nageru/alsa_pool.cpp
Examining data/nageru-2.0.1/nageru/alsa_pool.h
Examining data/nageru-2.0.1/nageru/analyzer.cpp
Examining data/nageru-2.0.1/nageru/analyzer.h
Examining data/nageru-2.0.1/nageru/audio_encoder.cpp
Examining data/nageru-2.0.1/nageru/audio_encoder.h
Examining data/nageru-2.0.1/nageru/audio_mixer.cpp
Examining data/nageru-2.0.1/nageru/audio_mixer.h
Examining data/nageru-2.0.1/nageru/basic_stats.cpp
Examining data/nageru-2.0.1/nageru/basic_stats.h
Examining data/nageru-2.0.1/nageru/benchmark_audio_mixer.cpp
Examining data/nageru-2.0.1/nageru/card_type.h
Examining data/nageru-2.0.1/nageru/cef_capture.cpp
Examining data/nageru-2.0.1/nageru/cef_capture.h
Examining data/nageru-2.0.1/nageru/chroma_subsampler.cpp
Examining data/nageru-2.0.1/nageru/chroma_subsampler.h
Examining data/nageru-2.0.1/nageru/clickable_label.h
Examining data/nageru-2.0.1/nageru/compression_reduction_meter.cpp
Examining data/nageru-2.0.1/nageru/compression_reduction_meter.h
Examining data/nageru-2.0.1/nageru/context.h
Examining data/nageru-2.0.1/nageru/context_menus.cpp
Examining data/nageru-2.0.1/nageru/context_menus.h
Examining data/nageru-2.0.1/nageru/correlation_measurer.cpp
Examining data/nageru-2.0.1/nageru/correlation_measurer.h
Examining data/nageru-2.0.1/nageru/correlation_meter.cpp
Examining data/nageru-2.0.1/nageru/correlation_meter.h
Examining data/nageru-2.0.1/nageru/decibel.h
Examining data/nageru-2.0.1/nageru/decklink/DeckLinkAPI.h
Examining data/nageru-2.0.1/nageru/decklink/DeckLinkAPIConfiguration.h
Examining data/nageru-2.0.1/nageru/decklink/DeckLinkAPIDeckControl.h
Examining data/nageru-2.0.1/nageru/decklink/DeckLinkAPIDiscovery.h
Examining data/nageru-2.0.1/nageru/decklink/DeckLinkAPIDispatch.cpp
Examining data/nageru-2.0.1/nageru/decklink/DeckLinkAPIModes.h
Examining data/nageru-2.0.1/nageru/decklink/DeckLinkAPITypes.h
Examining data/nageru-2.0.1/nageru/decklink/LinuxCOM.h
Examining data/nageru-2.0.1/nageru/decklink_capture.cpp
Examining data/nageru-2.0.1/nageru/decklink_capture.h
Examining data/nageru-2.0.1/nageru/decklink_output.cpp
Examining data/nageru-2.0.1/nageru/decklink_output.h
Examining data/nageru-2.0.1/nageru/decklink_util.cpp
Examining data/nageru-2.0.1/nageru/decklink_util.h
Examining data/nageru-2.0.1/nageru/defs.h
Examining data/nageru-2.0.1/nageru/ebu_r128_proc.cc
Examining data/nageru-2.0.1/nageru/ebu_r128_proc.h
Examining data/nageru-2.0.1/nageru/ellipsis_label.h
Examining data/nageru-2.0.1/nageru/embedded_files.h
Examining data/nageru-2.0.1/nageru/experiments/queue_drop_policy.cpp
Examining data/nageru-2.0.1/nageru/ffmpeg_capture.cpp
Examining data/nageru-2.0.1/nageru/ffmpeg_capture.h
Examining data/nageru-2.0.1/nageru/ffmpeg_util.cpp
Examining data/nageru-2.0.1/nageru/ffmpeg_util.h
Examining data/nageru-2.0.1/nageru/filter.cpp
Examining data/nageru-2.0.1/nageru/filter.h
Examining data/nageru-2.0.1/nageru/flags.cpp
Examining data/nageru-2.0.1/nageru/flags.h
Examining data/nageru-2.0.1/nageru/glwidget.cpp
Examining data/nageru-2.0.1/nageru/glwidget.h
Examining data/nageru-2.0.1/nageru/image_input.cpp
Examining data/nageru-2.0.1/nageru/image_input.h
Examining data/nageru-2.0.1/nageru/input_mapping.cpp
Examining data/nageru-2.0.1/nageru/input_mapping.h
Examining data/nageru-2.0.1/nageru/input_mapping_dialog.cpp
Examining data/nageru-2.0.1/nageru/input_mapping_dialog.h
Examining data/nageru-2.0.1/nageru/input_state.h
Examining data/nageru-2.0.1/nageru/kaeru.cpp
Examining data/nageru-2.0.1/nageru/lrameter.cpp
Examining data/nageru-2.0.1/nageru/lrameter.h
Examining data/nageru-2.0.1/nageru/lua_utils.h
Examining data/nageru-2.0.1/nageru/main.cpp
Examining data/nageru-2.0.1/nageru/mainwindow.cpp
Examining data/nageru-2.0.1/nageru/mainwindow.h
Examining data/nageru-2.0.1/nageru/midi_mapper.cpp
Examining data/nageru-2.0.1/nageru/midi_mapper.h
Examining data/nageru-2.0.1/nageru/midi_mapping_dialog.cpp
Examining data/nageru-2.0.1/nageru/midi_mapping_dialog.h
Examining data/nageru-2.0.1/nageru/mixer.cpp
Examining data/nageru-2.0.1/nageru/mixer.h
Examining data/nageru-2.0.1/nageru/mjpeg_encoder.cpp
Examining data/nageru-2.0.1/nageru/mjpeg_encoder.h
Examining data/nageru-2.0.1/nageru/nageru_cef_app.cpp
Examining data/nageru-2.0.1/nageru/nageru_cef_app.h
Examining data/nageru-2.0.1/nageru/nonlinear_fader.cpp
Examining data/nageru-2.0.1/nageru/nonlinear_fader.h
Examining data/nageru-2.0.1/nageru/pbo_frame_allocator.cpp
Examining data/nageru-2.0.1/nageru/pbo_frame_allocator.h
Examining data/nageru-2.0.1/nageru/piecewise_interpolator.cpp
Examining data/nageru-2.0.1/nageru/piecewise_interpolator.h
Examining data/nageru-2.0.1/nageru/print_latency.cpp
Examining data/nageru-2.0.1/nageru/print_latency.h
Examining data/nageru-2.0.1/nageru/quicksync_encoder.cpp
Examining data/nageru-2.0.1/nageru/quicksync_encoder.h
Examining data/nageru-2.0.1/nageru/quicksync_encoder_impl.h
Examining data/nageru-2.0.1/nageru/quittable_sleeper.h
Examining data/nageru-2.0.1/nageru/ref_counted_frame.cpp
Examining data/nageru-2.0.1/nageru/ref_counted_frame.h
Examining data/nageru-2.0.1/nageru/resampling_queue.cpp
Examining data/nageru-2.0.1/nageru/resampling_queue.h
Examining data/nageru-2.0.1/nageru/scene.cpp
Examining data/nageru-2.0.1/nageru/scene.h
Examining data/nageru-2.0.1/nageru/stereocompressor.cpp
Examining data/nageru-2.0.1/nageru/stereocompressor.h
Examining data/nageru-2.0.1/nageru/theme.cpp
Examining data/nageru-2.0.1/nageru/theme.h
Examining data/nageru-2.0.1/nageru/timecode_renderer.cpp
Examining data/nageru-2.0.1/nageru/timecode_renderer.h
Examining data/nageru-2.0.1/nageru/tweaked_inputs.cpp
Examining data/nageru-2.0.1/nageru/tweaked_inputs.h
Examining data/nageru-2.0.1/nageru/v210_converter.cpp
Examining data/nageru-2.0.1/nageru/v210_converter.h
Examining data/nageru-2.0.1/nageru/v4l_output.cpp
Examining data/nageru-2.0.1/nageru/v4l_output.h
Examining data/nageru-2.0.1/nageru/video_encoder.cpp
Examining data/nageru-2.0.1/nageru/video_encoder.h
Examining data/nageru-2.0.1/nageru/vu_common.cpp
Examining data/nageru-2.0.1/nageru/vu_common.h
Examining data/nageru-2.0.1/nageru/vumeter.cpp
Examining data/nageru-2.0.1/nageru/vumeter.h
Examining data/nageru-2.0.1/nageru/x264_dynamic.cpp
Examining data/nageru-2.0.1/nageru/x264_dynamic.h
Examining data/nageru-2.0.1/nageru/x264_encoder.cpp
Examining data/nageru-2.0.1/nageru/x264_encoder.h
Examining data/nageru-2.0.1/nageru/x264_speed_control.cpp
Examining data/nageru-2.0.1/nageru/x264_speed_control.h
Examining data/nageru-2.0.1/nageru/ycbcr_interpretation.h
Examining data/nageru-2.0.1/shared/aboutdialog.cpp
Examining data/nageru-2.0.1/shared/aboutdialog.h
Examining data/nageru-2.0.1/shared/bin2h.cpp
Examining data/nageru-2.0.1/shared/context.cpp
Examining data/nageru-2.0.1/shared/context.h
Examining data/nageru-2.0.1/shared/controller_spin_box.h
Examining data/nageru-2.0.1/shared/disk_space_estimator.cpp
Examining data/nageru-2.0.1/shared/disk_space_estimator.h
Examining data/nageru-2.0.1/shared/ffmpeg_raii.cpp
Examining data/nageru-2.0.1/shared/ffmpeg_raii.h
Examining data/nageru-2.0.1/shared/httpd.cpp
Examining data/nageru-2.0.1/shared/httpd.h
Examining data/nageru-2.0.1/shared/memcpy_interleaved.cpp
Examining data/nageru-2.0.1/shared/memcpy_interleaved.h
Examining data/nageru-2.0.1/shared/metacube2.cpp
Examining data/nageru-2.0.1/shared/metacube2.h
Examining data/nageru-2.0.1/shared/metrics.cpp
Examining data/nageru-2.0.1/shared/metrics.h
Examining data/nageru-2.0.1/shared/midi_device.cpp
Examining data/nageru-2.0.1/shared/midi_device.h
Examining data/nageru-2.0.1/shared/midi_mapper_util.h
Examining data/nageru-2.0.1/shared/mux.cpp
Examining data/nageru-2.0.1/shared/mux.h
Examining data/nageru-2.0.1/shared/post_to_main_thread.h
Examining data/nageru-2.0.1/shared/read_file.cpp
Examining data/nageru-2.0.1/shared/read_file.h
Examining data/nageru-2.0.1/shared/ref_counted_gl_sync.h
Examining data/nageru-2.0.1/shared/ref_counted_texture.cpp
Examining data/nageru-2.0.1/shared/ref_counted_texture.h
Examining data/nageru-2.0.1/shared/shared_defs.h
Examining data/nageru-2.0.1/shared/text_proto.cpp
Examining data/nageru-2.0.1/shared/text_proto.h
Examining data/nageru-2.0.1/shared/timebase.h
Examining data/nageru-2.0.1/shared/va_display.cpp
Examining data/nageru-2.0.1/shared/va_display.h
Examining data/nageru-2.0.1/shared/va_resource_pool.cpp
Examining data/nageru-2.0.1/shared/va_resource_pool.h

FINAL RESULTS:

data/nageru-2.0.1/nageru/experiments/queue_drop_policy.cpp:546:7:  [4] (buffer) fscanf:
  The scanf() family's %s operation, without a limit specification, permits
  buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a
  different input function.
		if (fscanf(fp, "%s %lf", dir, &t) != 2) {
data/nageru-2.0.1/nageru/ffmpeg_util.cpp:40:7:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
		if (access(pathname.c_str(), O_RDONLY) == 0) {
data/nageru-2.0.1/nageru/theme.cpp:71:2:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
	vsnprintf(buf, sizeof(buf), format, ap);
data/nageru-2.0.1/shared/midi_device.cpp:38:3:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		fprintf(stderr, msg ": %s\n", snd_strerror(err));  \
data/nageru-2.0.1/shared/midi_device.cpp:46:3:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
		fprintf(stderr, msg ": %s\n", snd_strerror(err));  \
data/nageru-2.0.1/futatabi/flags.cpp:70:11:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		int c = getopt_long(argc, argv, "w:h:r:q:d:l:", long_options, &option_index);
data/nageru-2.0.1/futatabi/flow_main.cpp:433:11:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		int c = getopt_long(argc, argv, "s:i:g:", long_options, &option_index);
data/nageru-2.0.1/futatabi/vaapi_jpeg_decoder.cpp:88:6:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if (getenv("LIBVA_MESSAGING_LEVEL") == nullptr) {
data/nageru-2.0.1/nageru/experiments/queue_drop_policy.cpp:513:11:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		int c = getopt_long(argc, argv, "d:u:l:", long_options, &option_index);
data/nageru-2.0.1/nageru/flags.cpp:305:11:  [3] (buffer) getopt_long:
  Some older implementations do not protect against internal buffer overflows
  (CWE-120, CWE-20). Check implementation on installation, or limit the size
  of all string inputs.
		int c = getopt_long(argc, argv, "c:o:t:I:r:v:m:M:w:h:", long_options, &option_index);
data/nageru-2.0.1/nageru/quicksync_encoder.cpp:2065:6:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if (getenv("LIBVA_MESSAGING_LEVEL") == nullptr) {
data/nageru-2.0.1/nageru/theme.cpp:1537:31:  [3] (buffer) realpath:
  This function does not protect against buffer overflows, and some
  implementations can overflow internally (CWE-120/CWE-785!). Ensure that the
  destination buffer is at least of size MAXPATHLEN, andto protect against
  implementation problems, the input argument should also be checked to
  ensure it is no larger than MAXPATHLEN.
		char *absolute_theme_path = realpath(path.c_str(), nullptr);
data/nageru-2.0.1/futatabi/clip_list.cpp:24:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/futatabi/clip_list.cpp:38:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/futatabi/flags.cpp:77:25:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.width = atoi(optarg);
data/nageru-2.0.1/futatabi/flags.cpp:80:26:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.height = atoi(optarg);
data/nageru-2.0.1/futatabi/flags.cpp:98:41:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.interpolation_quality = atoi(optarg);
data/nageru-2.0.1/futatabi/flags.cpp:117:29:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.http_port = atoi(optarg);
data/nageru-2.0.1/futatabi/flow.cpp:79:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
				char buf[32];
data/nageru-2.0.1/futatabi/flow.cpp:568:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char timer_name[256];
data/nageru-2.0.1/futatabi/flow_main.cpp:77:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(pix.get() + y * width * 4, sptr + y2 * rgb_surf->pitch, width * 4);
data/nageru-2.0.1/futatabi/flow_main.cpp:113:17:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *flowfp = fopen(filename, "wb");
data/nageru-2.0.1/futatabi/flow_main.cpp:132:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *fp = fopen(filename, "wb");
data/nageru-2.0.1/futatabi/flow_main.cpp:154:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *fp = fopen(filename, "wb");
data/nageru-2.0.1/futatabi/flow_main.cpp:159:4:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
			memcpy(&rgb_line[x * 3], &rgba[(y2 * width + x) * 4], 4);
data/nageru-2.0.1/futatabi/flow_main.cpp:192:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(flow.get(), buf, width * height * bytes_per_pixel);  // TODO: Unneeded for RGBType, since flip_coordinate_system() does nothing.:
data/nageru-2.0.1/futatabi/flow_main.cpp:401:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char ppm_filename[256];
data/nageru-2.0.1/futatabi/frame_on_disk.cpp:89:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fd = open(filename.c_str(), O_RDONLY);
data/nageru-2.0.1/futatabi/main.cpp:81:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char filename[256];
data/nageru-2.0.1/futatabi/main.cpp:84:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		FILE *fp = fopen(filename, "wb");
data/nageru-2.0.1/futatabi/main.cpp:310:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *fp = fopen(filename, "rb");
data/nageru-2.0.1/futatabi/mainwindow.cpp:307:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char title[256];
data/nageru-2.0.1/futatabi/mainwindow.cpp:1067:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char time_str[256];
data/nageru-2.0.1/futatabi/mainwindow.cpp:1069:3:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
		strcpy(time_str, "<font color=\"red\">Less than a minute</font>");
data/nageru-2.0.1/futatabi/mainwindow.cpp:1087:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/futatabi/midi_mapping_dialog.cpp:120:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char str[256];
data/nageru-2.0.1/futatabi/player.cpp:893:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/futatabi/util.cpp:11:17:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *flowfp = fopen(filename, "rb");
data/nageru-2.0.1/futatabi/vaapi_jpeg_decoder.cpp:36:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(dst, src, src_width * height);
data/nageru-2.0.1/futatabi/vaapi_jpeg_decoder.cpp:41:4:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
			memcpy(dptr, sptr, src_width);
data/nageru-2.0.1/futatabi/vaapi_jpeg_decoder.cpp:389:4:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
			memcpy(dptr + y * width, sptr + y * spitch, width);
data/nageru-2.0.1/futatabi/vis.cpp:20:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *fp = fopen(argv[2], "wb");
data/nageru-2.0.1/nageru/alsa_input.cpp:178:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char thread_name[16];
data/nageru-2.0.1/nageru/alsa_pool.cpp:84:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char address[256];
data/nageru-2.0.1/nageru/alsa_pool.cpp:104:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char address[256];
data/nageru-2.0.1/nageru/alsa_pool.cpp:135:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char address[256];
data/nageru-2.0.1/nageru/alsa_pool.cpp:138:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char thread_name[16];
data/nageru-2.0.1/nageru/alsa_pool.cpp:178:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char address[256];
data/nageru-2.0.1/nageru/alsa_pool.cpp:282:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char address[256];
data/nageru-2.0.1/nageru/analyzer.cpp:156:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(grabbed_image.scanLine(global_flags.height - y - 1), buf + y * pitch, pitch);
data/nageru-2.0.1/nageru/analyzer.cpp:160:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[256];
data/nageru-2.0.1/nageru/analyzer.cpp:277:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[256];
data/nageru-2.0.1/nageru/audio_mixer.cpp:1161:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char bus_index_str[16], source_index_str[16], source_channels_str[64];
data/nageru-2.0.1/nageru/audio_mixer.cpp:1270:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/nageru/benchmark_audio_mixer.cpp:116:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *fp = fopen(filename, "rb");
data/nageru-2.0.1/nageru/benchmark_audio_mixer.cpp:119:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fp = fopen(filename, "wb");
data/nageru-2.0.1/nageru/cef_capture.cpp:30:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/nageru/cef_capture.cpp:146:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(video_frame.data, buffer, width * height * 4);
data/nageru-2.0.1/nageru/cef_capture.cpp:214:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/nageru/compression_reduction_meter.cpp:83:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[256];
data/nageru-2.0.1/nageru/decklink_capture.cpp:55:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[256];
data/nageru-2.0.1/nageru/decklink_capture.cpp:126:4:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			char buf[256];
data/nageru-2.0.1/nageru/decklink_capture.cpp:212:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char thread_name[16];
data/nageru-2.0.1/nageru/decklink_capture.cpp:266:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(current_video_frame.data, src, num_bytes);
data/nageru-2.0.1/nageru/decklink_capture.cpp:269:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(current_video_frame.data_copy, src, num_bytes);
data/nageru-2.0.1/nageru/decklink_capture.cpp:288:4:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
			memcpy(current_audio_frame.data, src, current_audio_frame.len);
data/nageru-2.0.1/nageru/decklink_output.cpp:593:4:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
			memcpy(frame->uyvy_ptr_local.get(), frame->uyvy_ptr, v210Converter::get_v210_stride(width) * height);
data/nageru-2.0.1/nageru/decklink_output.cpp:595:4:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
			memcpy(frame->uyvy_ptr_local.get(), frame->uyvy_ptr, width * height * 2);
data/nageru-2.0.1/nageru/experiments/queue_drop_policy.cpp:250:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char name[256];
data/nageru-2.0.1/nageru/experiments/queue_drop_policy.cpp:498:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char name[256];
data/nageru-2.0.1/nageru/experiments/queue_drop_policy.cpp:537:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *fp = fopen(filename, "r");
data/nageru-2.0.1/nageru/experiments/queue_drop_policy.cpp:543:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char dir[256];
data/nageru-2.0.1/nageru/ffmpeg_capture.cpp:340:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/nageru/ffmpeg_capture.cpp:356:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char thread_name[16];
data/nageru-2.0.1/nageru/ffmpeg_util.cpp:43:4:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			char buf[512];
data/nageru-2.0.1/nageru/flags.cpp:91:30:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			range_begin = range_end = atoi(start);
data/nageru-2.0.1/nageru/flags.cpp:312:25:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.width = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:315:26:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.height = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:318:33:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.min_num_cards = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:321:33:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.max_num_cards = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:324:31:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.output_card = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:342:27:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			const int signal_num = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:343:25:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			const int card_num = atoi(ptr + 1);
data/nageru-2.0.1/nageru/flags.cpp:384:46:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.stream_audio_codec_bitrate = atoi(optarg) * 1000;
data/nageru-2.0.1/nageru/flags.cpp:387:29:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.http_port = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:390:28:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.srt_port = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:422:32:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.x264_bitrate = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:428:40:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.x264_vbv_buffer_size = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:431:40:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.x264_vbv_max_bitrate = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:488:42:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			global_flags.max_input_queue_frames = atoi(optarg);
data/nageru-2.0.1/nageru/flags.cpp:527:25:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			const int card_num = atoi(optarg);
data/nageru-2.0.1/nageru/input_mapping_dialog.cpp:179:5:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
				char buf[256];
data/nageru-2.0.1/nageru/mainwindow.cpp:140:4:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			char buf[256];
data/nageru-2.0.1/nageru/mainwindow.cpp:151:4:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			char buf[256];
data/nageru-2.0.1/nageru/mainwindow.cpp:282:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char title[256];
data/nageru-2.0.1/nageru/mainwindow.cpp:798:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/nageru/mainwindow.cpp:811:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char time_str[256];
data/nageru-2.0.1/nageru/mainwindow.cpp:813:3:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
		strcpy(time_str, "<font color=\"red\">Less than a minute</font>");
data/nageru-2.0.1/nageru/mainwindow.cpp:831:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/nageru/mainwindow.cpp:882:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[256];
data/nageru-2.0.1/nageru/midi_mapping_dialog.cpp:166:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[256];
data/nageru-2.0.1/nageru/mixer.cpp:392:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char url[256];
data/nageru-2.0.1/nageru/mixer.cpp:647:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char name[32];
data/nageru-2.0.1/nageru/mixer.cpp:745:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char card_name[64];
data/nageru-2.0.1/nageru/mixer.cpp:1677:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char name[256];
data/nageru-2.0.1/nageru/mixer.cpp:2292:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[256];
data/nageru-2.0.1/nageru/mixer.cpp:2297:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[256];
data/nageru-2.0.1/nageru/mixer.cpp:2311:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/nageru/print_latency.cpp:38:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char card_index_str[64];
data/nageru-2.0.1/nageru/print_latency.cpp:42:4:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			char frame_index_str[64];
data/nageru-2.0.1/nageru/quicksync_encoder.cpp:868:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(tmp_surfaceid, src_surface, SURFACE_NUM * sizeof(VASurfaceID));
data/nageru-2.0.1/nageru/quicksync_encoder.cpp:869:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(tmp_surfaceid + SURFACE_NUM, ref_surface, SURFACE_NUM * sizeof(VASurfaceID));
data/nageru-2.0.1/nageru/quicksync_encoder.cpp:1261:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(slice_param.RefPicList0, RefPicList0_P, refpiclist0_max*sizeof(VAPictureH264));
data/nageru-2.0.1/nageru/quicksync_encoder.cpp:1274:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(slice_param.RefPicList0, RefPicList0_B, refpiclist0_max*sizeof(VAPictureH264));
data/nageru-2.0.1/nageru/quicksync_encoder.cpp:1280:9:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        memcpy(slice_param.RefPicList1, RefPicList1_B, refpiclist1_max*sizeof(VAPictureH264));
data/nageru-2.0.1/nageru/quicksync_encoder.cpp:1727:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char tmp[AV_ERROR_MAX_STRING_SIZE];
data/nageru-2.0.1/nageru/quicksync_encoder.cpp:1871:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(dst, src, src_width * height);
data/nageru-2.0.1/nageru/quicksync_encoder.cpp:1876:4:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
			memcpy(dptr, sptr, src_width);
data/nageru-2.0.1/nageru/scene.cpp:43:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/nageru/theme.cpp:68:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[4096];
data/nageru-2.0.1/nageru/theme.cpp:729:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/nageru/theme.cpp:741:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[256];
data/nageru-2.0.1/nageru/timecode_renderer.cpp:83:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char clock_text[256];
data/nageru-2.0.1/nageru/timecode_renderer.cpp:96:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char timecode_text[512];
data/nageru-2.0.1/nageru/v210_converter.cpp:41:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[16];
data/nageru-2.0.1/nageru/v4l_output.cpp:19:13:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	video_fd = open(device_path, O_WRONLY);
data/nageru-2.0.1/nageru/v4l_output.cpp:54:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(yuv420_buf.get(), data, luma_size);
data/nageru-2.0.1/nageru/video_encoder.cpp:37:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char timestamp[64];
data/nageru-2.0.1/nageru/video_encoder.cpp:42:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char filename[256];
data/nageru-2.0.1/nageru/x264_dynamic.cpp:82:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char x264_encoder_open_symname[256];
data/nageru-2.0.1/nageru/x264_encoder.cpp:125:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(qf.data, data, global_flags.width * global_flags.height * 2 * bytes_per_pixel);
data/nageru-2.0.1/nageru/x264_encoder.cpp:251:35:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
				buffered_sei += string((const char *)nal[i].p_payload, nal[i].i_payload);
data/nageru-2.0.1/nageru/x264_encoder.cpp:253:37:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
				global_headers += string((const char *)nal[i].p_payload, nal[i].i_payload);
data/nageru-2.0.1/nageru/x264_encoder.cpp:396:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(ptr, buffered_sei.data(), buffered_sei.size());
data/nageru-2.0.1/nageru/x264_encoder.cpp:401:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(ptr, nal[i].p_payload, nal[i].i_payload);
data/nageru-2.0.1/shared/bin2h.cpp:20:15:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *infp = fopen(argv[1], "rb");
data/nageru-2.0.1/shared/bin2h.cpp:26:16:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *outfp = fopen(argv[3], "w");
data/nageru-2.0.1/shared/httpd.cpp:115:21:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		stream_id.index = atoi(url + 7);
data/nageru-2.0.1/shared/httpd.cpp:236:4:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
			memcpy(buf, s.data() + used_of_buffered_data, len);
data/nageru-2.0.1/shared/httpd.cpp:245:4:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
			memcpy(buf, s.data() + used_of_buffered_data, max);
data/nageru-2.0.1/shared/metacube2.h:27:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char sync[8];    /* METACUBE2_SYNC */
data/nageru-2.0.1/shared/mux.cpp:89:3:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
		memcpy(avstream_video->codecpar->extradata, video_extradata.data(), video_extradata.size());
data/nageru-2.0.1/shared/read_file.cpp:9:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	FILE *fp = fopen(filename.c_str(), "r");
data/nageru-2.0.1/shared/text_proto.cpp:15:11:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	int fd = open(filename.c_str(), O_RDONLY);
data/nageru-2.0.1/shared/text_proto.cpp:33:11:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	int fd = open(filename.c_str(), O_WRONLY | O_TRUNC | O_CREAT, 0666);
data/nageru-2.0.1/shared/va_display.cpp:46:16:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		int drm_fd = open(va_display.c_str(), O_RDWR);
data/nageru-2.0.1/shared/va_display.cpp:74:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[256];
data/nageru-2.0.1/shared/va_display.cpp:118:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[256];
data/nageru-2.0.1/shared/va_display.cpp:133:4:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
			char buf[256];
data/nageru-2.0.1/shared/va_display.cpp:143:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(request.image_format, &formats[i], sizeof(VAImageFormat));
data/nageru-2.0.1/futatabi/flow.cpp:66:6:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strlen(info_log) > 0) {
data/nageru-2.0.1/futatabi/flow_main.cpp:191:36:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	void *buf = glMapNamedBufferRange(read.pbo, 0, width * height * bytes_per_pixel, GL_MAP_READ_BIT);  // Blocks if the read isn't done yet.
data/nageru-2.0.1/futatabi/flow_main.cpp:193:21:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	glUnmapNamedBuffer(read.pbo);
data/nageru-2.0.1/futatabi/flow_main.cpp:194:18:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	spare_pbos.push(read.pbo);
data/nageru-2.0.1/futatabi/flow_main.cpp:197:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (!read.flow_filename.empty()) {
data/nageru-2.0.1/futatabi/flow_main.cpp:198:14:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		write_flow(read.flow_filename.c_str(), flow.get(), width, height);
data/nageru-2.0.1/futatabi/flow_main.cpp:199:36:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		fprintf(stderr, "%s %s -> %s\n", read.filename0.c_str(), read.filename1.c_str(), read.flow_filename.c_str());
data/nageru-2.0.1/futatabi/flow_main.cpp:199:60:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		fprintf(stderr, "%s %s -> %s\n", read.filename0.c_str(), read.filename1.c_str(), read.flow_filename.c_str());
data/nageru-2.0.1/futatabi/flow_main.cpp:199:84:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		fprintf(stderr, "%s %s -> %s\n", read.filename0.c_str(), read.filename1.c_str(), read.flow_filename.c_str());
data/nageru-2.0.1/futatabi/flow_main.cpp:201:7:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (!read.ppm_filename.empty()) {
data/nageru-2.0.1/futatabi/flow_main.cpp:202:13:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		write_ppm(read.ppm_filename.c_str(), flow.get(), width, height);
data/nageru-2.0.1/futatabi/main.cpp:331:12:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		int ch = getc(fp);
data/nageru-2.0.1/futatabi/video_stream.cpp:137:67:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	jpeg_write_marker(&cinfo, JPEG_COM, (const JOCTET *)"CS=ITU601", strlen("CS=ITU601"));
data/nageru-2.0.1/nageru/alsa_pool.cpp:344:9:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		ret = read(inotify_fd, buf.get(), size);
data/nageru-2.0.1/nageru/mainwindow.cpp:380:11:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
		if (i < strlen(qwerty)) {
data/nageru-2.0.1/nageru/mjpeg_encoder.cpp:554:66:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	jpeg_write_marker(cinfo, JPEG_COM, (const JOCTET *)"CS=ITU601", strlen("CS=ITU601"));
data/nageru-2.0.1/nageru/video_encoder.cpp:83:3:  [1] (obsolete) usleep:
  This C routine is considered obsolete (as opposed to the shell command by
  the same name). The interaction of this function with SIGALRM and other
  timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is
  unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead.
		usleep(10000);
data/nageru-2.0.1/nageru/x264_dynamic.cpp:57:43:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			x264_suffix = string(ptr, (m->l_name + strlen(m->l_name)) - ptr);
data/nageru-2.0.1/shared/bin2h.cpp:41:12:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		int ch = getc(infp);
data/nageru-2.0.1/shared/httpd.cpp:104:40:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strstr(url, ".metacube") == url + strlen(url) - strlen(".metacube")) {
data/nageru-2.0.1/shared/httpd.cpp:104:54:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	if (strstr(url, ".metacube") == url + strlen(url) - strlen(".metacube")) {

ANALYSIS SUMMARY:

Hits = 171
Lines analyzed = 48697 in approximately 1.20 seconds (40471 lines/second)
Physical Source Lines of Code (SLOC) = 37308
Hits@level = [0] 712 [1]  21 [2] 138 [3]   7 [4]   5 [5]   0
Hits@level+ = [0+] 883 [1+] 171 [2+] 150 [3+]  12 [4+]   5 [5+]   0
Hits/KSLOC@level+ = [0+] 23.6678 [1+] 4.58347 [2+] 4.02059 [3+] 0.321647 [4+] 0.13402 [5+]   0
Dot directories skipped = 1 (--followdotdir overrides)
Minimum risk level = 1
Not every hit is necessarily a security vulnerability.
There may be other security vulnerabilities; review your code!
See 'Secure Programming HOWTO'
(https://dwheeler.com/secure-programs) for more information.