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/guvcview-2.0.6+debian/includes/gview.h
Examining data/guvcview-2.0.6+debian/gview_encoder/avi.c
Examining data/guvcview-2.0.6+debian/gview_encoder/audio_codecs.c
Examining data/guvcview-2.0.6+debian/gview_encoder/file_io.h
Examining data/guvcview-2.0.6+debian/gview_encoder/encoder.c
Examining data/guvcview-2.0.6+debian/gview_encoder/file_io.c
Examining data/guvcview-2.0.6+debian/gview_encoder/encoder.h
Examining data/guvcview-2.0.6+debian/gview_encoder/libav_encoder.c
Examining data/guvcview-2.0.6+debian/gview_encoder/video_codecs.c
Examining data/guvcview-2.0.6+debian/gview_encoder/stream_io.h
Examining data/guvcview-2.0.6+debian/gview_encoder/avi.h
Examining data/guvcview-2.0.6+debian/gview_encoder/matroska.h
Examining data/guvcview-2.0.6+debian/gview_encoder/stream_io.c
Examining data/guvcview-2.0.6+debian/gview_encoder/matroska.c
Examining data/guvcview-2.0.6+debian/gview_encoder/muxer.c
Examining data/guvcview-2.0.6+debian/gview_encoder/gviewencoder.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/jpeg_decoder.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_core.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/uvc_h264.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_core.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/save_image_bmp.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/dct.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_devices.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_formats.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_devices.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_formats.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/frame_decoder.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/soft_autofocus.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/soft_autofocus.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/save_image.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_xu_ctrls.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/dct.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/gviewv4l2core.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_xu_ctrls.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/save_image_png.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/save_image.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/jpeg_decoder.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/uvc_h264.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/frame_decoder.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/core_time.h
Examining data/guvcview-2.0.6+debian/gview_v4l2core/core_time.c
Examining data/guvcview-2.0.6+debian/gview_v4l2core/save_image_jpeg.c
Examining data/guvcview-2.0.6+debian/gview_audio/audio.c
Examining data/guvcview-2.0.6+debian/gview_audio/audio_fx.c
Examining data/guvcview-2.0.6+debian/gview_audio/audio_pulseaudio.h
Examining data/guvcview-2.0.6+debian/gview_audio/audio_portaudio.c
Examining data/guvcview-2.0.6+debian/gview_audio/audio_pulseaudio.c
Examining data/guvcview-2.0.6+debian/gview_audio/gviewaudio.h
Examining data/guvcview-2.0.6+debian/gview_audio/core_time.h
Examining data/guvcview-2.0.6+debian/gview_audio/audio.h
Examining data/guvcview-2.0.6+debian/gview_audio/core_time.c
Examining data/guvcview-2.0.6+debian/gview_audio/audio_portaudio.h
Examining data/guvcview-2.0.6+debian/gview_render/render.c
Examining data/guvcview-2.0.6+debian/gview_render/render_osd_crosshair.c
Examining data/guvcview-2.0.6+debian/gview_render/render_sfml.h
Examining data/guvcview-2.0.6+debian/gview_render/render.h
Examining data/guvcview-2.0.6+debian/gview_render/render_sfml.hpp
Examining data/guvcview-2.0.6+debian/gview_render/render_sdl2.h
Examining data/guvcview-2.0.6+debian/gview_render/render_sfml.cpp
Examining data/guvcview-2.0.6+debian/gview_render/render_osd_vu_meter.c
Examining data/guvcview-2.0.6+debian/gview_render/gviewrender.h
Examining data/guvcview-2.0.6+debian/gview_render/render_sdl2.c
Examining data/guvcview-2.0.6+debian/gview_render/render_fx.c
Examining data/guvcview-2.0.6+debian/guvcview/guvcview.c
Examining data/guvcview-2.0.6+debian/guvcview/gui_qt5.hpp
Examining data/guvcview-2.0.6+debian/guvcview/gui_gtk3_videoctrls.c
Examining data/guvcview-2.0.6+debian/guvcview/gui_gtk3.h
Examining data/guvcview-2.0.6+debian/guvcview/gui.h
Examining data/guvcview-2.0.6+debian/guvcview/gui_gtk3_v4l2ctrls.c
Examining data/guvcview-2.0.6+debian/guvcview/video_capture.h
Examining data/guvcview-2.0.6+debian/guvcview/gui_gtk3_callbacks.h
Examining data/guvcview-2.0.6+debian/guvcview/gui_qt5_videoctrls.cpp
Examining data/guvcview-2.0.6+debian/guvcview/gui_gtk3.c
Examining data/guvcview-2.0.6+debian/guvcview/gui_gtk3_audioctrls.c
Examining data/guvcview-2.0.6+debian/guvcview/gui.c
Examining data/guvcview-2.0.6+debian/guvcview/options.c
Examining data/guvcview-2.0.6+debian/guvcview/gui_qt5.h
Examining data/guvcview-2.0.6+debian/guvcview/gui_qt5_menu.cpp
Examining data/guvcview-2.0.6+debian/guvcview/gui_qt5_audioctrls.cpp
Examining data/guvcview-2.0.6+debian/guvcview/gui_gtk3_callbacks.c
Examining data/guvcview-2.0.6+debian/guvcview/core_io.h
Examining data/guvcview-2.0.6+debian/guvcview/video_capture.c
Examining data/guvcview-2.0.6+debian/guvcview/gui_qt5_callbacks.cpp
Examining data/guvcview-2.0.6+debian/guvcview/gui_qt5_h264ctrls.cpp
Examining data/guvcview-2.0.6+debian/guvcview/options.h
Examining data/guvcview-2.0.6+debian/guvcview/gui_gtk3_h264ctrls.c
Examining data/guvcview-2.0.6+debian/guvcview/config.c
Examining data/guvcview-2.0.6+debian/guvcview/gui_qt5_v4l2ctrls.cpp
Examining data/guvcview-2.0.6+debian/guvcview/core_io.c
Examining data/guvcview-2.0.6+debian/guvcview/gui_qt5.cpp
Examining data/guvcview-2.0.6+debian/guvcview/config.h
Examining data/guvcview-2.0.6+debian/guvcview/gui_gtk3_menu.c

FINAL RESULTS:

data/guvcview-2.0.6+debian/guvcview/core_io.c:81:3:  [4] (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).
		strcpy(src, tmp);
data/guvcview-2.0.6+debian/guvcview/core_io.c:420:5:  [4] (buffer) sscanf:
  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 the scanf format is influenceable by an
  attacker, it's exploitable.
				sscanf(ent->d_name, format_str, sfixstr);
data/guvcview-2.0.6+debian/guvcview/core_io.c:502:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(new_name, "%s-%llu.%s", noextname, suffix, extension);
data/guvcview-2.0.6+debian/guvcview/core_io.c:507:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(new_name, "%s-%llu", filename, suffix);
data/guvcview-2.0.6+debian/gview_audio/audio_portaudio.c:232:6:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
					printf( (defaultDisplayed ? "," : "[") );
data/guvcview-2.0.6+debian/gview_audio/audio_portaudio.c:242:6:  [4] (format) printf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
					printf( (defaultDisplayed ? "," : "[") );
data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c:219:8:  [4] (buffer) sscanf:
  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 the scanf format is influenceable by an
  attacker, it's exploitable.
							sscanf(line, fmt, str);
data/guvcview-2.0.6+debian/guvcview/gui.c:465:25:  [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.
		profile_path = strdup(getenv("HOME"));
data/guvcview-2.0.6+debian/guvcview/gui.c:654:23:  [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.
		video_path = strdup(getenv("HOME"));
data/guvcview-2.0.6+debian/guvcview/gui.c:845:23:  [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.
		photo_path = strdup(getenv("HOME"));
data/guvcview-2.0.6+debian/guvcview/guvcview.c:122:32:  [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.
	char *config_path = smart_cat(getenv("HOME"), '/', ".config/guvcview2");
data/guvcview-2.0.6+debian/guvcview/options.c:459:16:  [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.
	while ((opt = getopt_long(argc, argv, opt_string,
data/guvcview-2.0.6+debian/guvcview/config.c:104:11:  [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).
	if((fp = fopen(filename,"w")) == NULL)
data/guvcview-2.0.6+debian/guvcview/config.c:196: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 bufr[MAXLINE];
data/guvcview-2.0.6+debian/guvcview/config.c:200:11:  [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).
	if((fp = fopen(filename,"r")) == NULL)
data/guvcview-2.0.6+debian/guvcview/config.h:32: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 render[5];  /*render api*/
data/guvcview-2.0.6+debian/guvcview/config.h:33: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 gui[5];     /*gui api*/
data/guvcview-2.0.6+debian/guvcview/config.h:34: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 audio[6];   /*audio api - none; port; pulse*/
data/guvcview-2.0.6+debian/guvcview/config.h:35: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 capture[5]; /*capture method: read or mmap*/
data/guvcview-2.0.6+debian/guvcview/config.h:36: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 video_codec[5]; /*video codec*/
data/guvcview-2.0.6+debian/guvcview/config.h: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 audio_codec[5]; /*video codec*/
data/guvcview-2.0.6+debian/guvcview/core_io.c:167: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(my_cat, dest, size_dest);
data/guvcview-2.0.6+debian/guvcview/core_io.c:175: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(my_p, str1, size_str1);
data/guvcview-2.0.6+debian/guvcview/core_io.c:396: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 format_str[fsize];
data/guvcview-2.0.6+debian/guvcview/core_io.c:418: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 sfixstr[21];
data/guvcview-2.0.6+debian/guvcview/gui_gtk3.c:545: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 videodevice[30];
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_callbacks.c:1145: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 videodevice[30];
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_callbacks.c:1246: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 temp_str[20];
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_callbacks.c:1321: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 temp_str[20];
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_v4l2ctrls.c:284:10:  [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 *) LEDMenu[j]);
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_v4l2ctrls.c:335:10:  [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 *) BITSMenu[j]);
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_v4l2ctrls.c:521:8:  [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 buffer[30]="0";
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_videoctrls.c:100: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 temp_str[20];
data/guvcview-2.0.6+debian/guvcview/gui_qt5_v4l2ctrls.cpp:285:27:  [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.
							combobox->addItem((char *) BITSMenu[j], current->menu[j].index);
data/guvcview-2.0.6+debian/guvcview/guvcview.c:249: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 message[50];
data/guvcview-2.0.6+debian/guvcview/guvcview.c:290: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 message[50];
data/guvcview-2.0.6+debian/guvcview/guvcview.c:305: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 message[50];
data/guvcview-2.0.6+debian/guvcview/options.c:44: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 opt_long[20];
data/guvcview-2.0.6+debian/guvcview/options.c:46: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 opt_help_arg[20];
data/guvcview-2.0.6+debian/guvcview/options.c:47: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 opt_help[80];
data/guvcview-2.0.6+debian/guvcview/options.c:430: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 opt_string[128] = "";
data/guvcview-2.0.6+debian/guvcview/options.c:470: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).
				my_options.verbosity = atoi(optarg);
data/guvcview-2.0.6+debian/guvcview/options.c:586: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).
				my_options.audio_device = atoi(optarg);
data/guvcview-2.0.6+debian/guvcview/options.c:682: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).
				my_options.photo_npics = atoi(optarg);
data/guvcview-2.0.6+debian/guvcview/options.h:28: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 device[30]; /*device name*/
data/guvcview-2.0.6+debian/guvcview/options.h:35: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 format[5];  /*pixelformat fourcc*/
data/guvcview-2.0.6+debian/guvcview/options.h:36: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 render[5];  /*render api*/
data/guvcview-2.0.6+debian/guvcview/options.h: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 gui[5];     /*gui api*/
data/guvcview-2.0.6+debian/guvcview/options.h: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 audio[6];   /*audio api - none; port; pulse*/
data/guvcview-2.0.6+debian/guvcview/options.h:40: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 capture[5]; /*capture method: read or mmap*/
data/guvcview-2.0.6+debian/guvcview/options.h: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 audio_codec[5]; /*audio codec*/
data/guvcview-2.0.6+debian/guvcview/options.h: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 video_codec[5]; /*video codec*/
data/guvcview-2.0.6+debian/guvcview/options.h:54: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 render_flag[5]; /*render window flag => default (none) | FULLSCREEN (full) | MAXIMIZED (max)*/
data/guvcview-2.0.6+debian/guvcview/video_capture.c:67:8:  [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.
static char render_caption[30]; /*render window caption*/
data/guvcview-2.0.6+debian/guvcview/video_capture.c:88:8:  [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.
static char status_message[80];
data/guvcview-2.0.6+debian/guvcview/video_capture.c:844: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(encoder_ctx->h264_pps, v4l2core_get_h264_pps(my_vd), encoder_ctx->h264_pps_size);
data/guvcview-2.0.6+debian/guvcview/video_capture.c:856: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(encoder_ctx->h264_sps, v4l2core_get_h264_sps(my_vd), encoder_ctx->h264_sps_size);
data/guvcview-2.0.6+debian/gview_audio/audio.c:302: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(audio_buffers[buffer_write_index].data,
data/guvcview-2.0.6+debian/gview_audio/audio.c:363: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( my_data, audio_buffers[buffer_read_index].data,
data/guvcview-2.0.6+debian/gview_audio/gviewaudio.h:91: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[512];         /*device name*/
data/guvcview-2.0.6+debian/gview_audio/gviewaudio.h:92: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 description[256];  /*device description*/
data/guvcview-2.0.6+debian/gview_encoder/audio_codecs.c:627: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(tmp, header_start[i] , header_len[i]);
data/guvcview-2.0.6+debian/gview_encoder/avi.c:410: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 tag[5];
data/guvcview-2.0.6+debian/gview_encoder/avi.c:754: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 tag[5];
data/guvcview-2.0.6+debian/gview_encoder/avi.c:821: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 tag[5];
data/guvcview-2.0.6+debian/gview_encoder/avi.c:884: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 tag[5];
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:293: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 fourcc[5];
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:1155: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(video_ring_buffer[video_write_index].frame, frame, size);
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:1513: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(enc_video_ctx->outbuf, input_frame, outsize);
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:1589: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(enc_video_ctx->outbuf, pkt->data, pkt->size);
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:1763: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(enc_audio_ctx->outbuf, pkt->data, pkt->size);
data/guvcview-2.0.6+debian/gview_encoder/file_io.c:122: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).
		writer->fp = fopen(filename, "wb");
data/guvcview-2.0.6+debian/gview_encoder/file_io.c:377: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(writer->buf_ptr, buf, len);
data/guvcview-2.0.6+debian/gview_encoder/gviewencoder.h:80: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 compressor[5];       //fourcc - upper case
data/guvcview-2.0.6+debian/gview_encoder/gviewencoder.h: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 mkv_codec[25];       //mkv codecID
data/guvcview-2.0.6+debian/gview_encoder/gviewencoder.h:84: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 description[35];     //codec description
data/guvcview-2.0.6+debian/gview_encoder/gviewencoder.h: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 codec_name[20];      //lavc codec_name
data/guvcview-2.0.6+debian/gview_encoder/gviewencoder.h:122: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 mkv_codec[25];       //mkv codecID
data/guvcview-2.0.6+debian/gview_encoder/gviewencoder.h:123: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 description[35];     //codec description
data/guvcview-2.0.6+debian/gview_encoder/gviewencoder.h:126: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 codec_name[20];      //lavc codec name
data/guvcview-2.0.6+debian/gview_encoder/gviewencoder.h:132: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[5];             //common 4cc name (lowercase)
data/guvcview-2.0.6+debian/gview_encoder/matroska.c:875: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(mkv_ctx->pkt_buffer_list[mkv_ctx->pkt_buffer_write_index].data, data, size);
data/guvcview-2.0.6+debian/gview_encoder/stream_io.h:50: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     compressor[8];      /* Type of compressor, 4 bytes + padding for 0 byte */
data/guvcview-2.0.6+debian/gview_encoder/video_codecs.c:744: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(tp, encoder_ctx->h264_sps , encoder_ctx->h264_sps_size);
data/guvcview-2.0.6+debian/gview_encoder/video_codecs.c:751: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(tp, encoder_ctx->h264_pps , encoder_ctx->h264_pps_size);
data/guvcview-2.0.6+debian/gview_encoder/video_codecs.c:839: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(tmp, header_start[i] , header_len[i]);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:239: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(line, pi, width);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:240: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(pi, pf, width);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:241: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(pf, line, width);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:253: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(line, pi, width / 2);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:254: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(pi, pf, width / 2);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:255: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(pf, line, width / 2);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:266: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(line, pi, width / 2);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:267: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(pi, pf, width / 2);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:268: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(pf, line, width / 2);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:303: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(line, pi, width);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:304: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(pf, line, width);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:316: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(line, pi, width / 2);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:317: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(pf, line, width / 2);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:328: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(line, pi, width / 2);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:329: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(pf, line, width / 2);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:1052: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(tcl, scl, width * height);
data/guvcview-2.0.6+debian/gview_render/render_fx.c:1114: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(tmpbuffer, frame, width * height * 3 / 2);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:640: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(out, in, width*height);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:1025: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(out, in, width*height);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:1027: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(out+(width*height), in+((width * height * 5) / 4), width * height / 4);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:1029: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(out+((width * height * 5) / 4), in+(width * height), width * height / 4);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:1053: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(out, in, width*height);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:1089: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(out, in, width*height);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:1125: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(out, in, width*height);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:1168: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(out, in, width*height);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:1211: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(out, in, width*height);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:1259: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(out, in, width*height);
data/guvcview-2.0.6+debian/gview_v4l2core/colorspaces.c:1475: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(out, in, width * height);
data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c:57:7:  [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, "w");
data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c:145:11:  [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).
	if((fp = fopen(filename,"r"))!=NULL)
data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c:147: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 line[200];
data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c:216:8:  [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[max+1];
data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c:217:8:  [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 fmt[48];
data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c:218:8:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
							sprintf(fmt,"ID{0x%%*x};CHK{%%*i:%%*i:%%*i:0}==STR{\"%%%is\"}", max);
data/guvcview-2.0.6+debian/gview_v4l2core/frame_decoder.c:464: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(*NALU, nal, nal_size);
data/guvcview-2.0.6+debian/gview_v4l2core/frame_decoder.c:549: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(ph264, sp, length);
data/guvcview-2.0.6+debian/gview_v4l2core/frame_decoder.c:579: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(ph264, sp, length);
data/guvcview-2.0.6+debian/gview_v4l2core/frame_decoder.c:594: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(ph264, sp, epl-sp);
data/guvcview-2.0.6+debian/gview_v4l2core/frame_decoder.c:669: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(vd->h264_last_IDR, frame->h264_frame, frame->h264_frame_size);
data/guvcview-2.0.6+debian/gview_v4l2core/frame_decoder.c:723: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(h264_data, buffer, size);
data/guvcview-2.0.6+debian/gview_v4l2core/frame_decoder.c:858: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->yuv_frame, frame->raw_frame, frame->raw_frame_size);
data/guvcview-2.0.6+debian/gview_v4l2core/gviewv4l2core.h:213: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 fourcc[5];      //corresponding fourcc (mode)
data/guvcview-2.0.6+debian/gview_v4l2core/gviewv4l2core.h: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 description[32];//format description
data/guvcview-2.0.6+debian/gview_v4l2core/jpeg_decoder.c:168:17:  [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.
static unsigned char zig2[64] = {
data/guvcview-2.0.6+debian/gview_v4l2core/jpeg_decoder.c:1026: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(jpeg_ctx->tmp_frame, in_buf, size);
data/guvcview-2.0.6+debian/gview_v4l2core/save_image.c:54:12:  [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).
	if ((fp = fopen(filename, "wb")) !=NULL)
data/guvcview-2.0.6+debian/gview_v4l2core/save_image_bmp.c:113:12:  [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).
	if ((fp = fopen(filename, "wb")) != NULL)
data/guvcview-2.0.6+debian/gview_v4l2core/save_image_png.c:63:7:  [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/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c:401:13:  [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(&(menu[i]), &querymenu, sizeof(struct v4l2_querymenu));
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c:450: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(&(control->control), queryctrl, sizeof(struct v4l2_queryctrl));
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c:879:36:  [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.
            clist[count].string = (char *) calloc(clist[count].size,  sizeof(char));
data/guvcview-2.0.6+debian/guvcview/config.c:217:14:  [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).
		int size = strlen(bufp);
data/guvcview-2.0.6+debian/guvcview/config.c:243:26:  [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(!token || !value || strlen(token) < 1 || strlen(value) < 1)
data/guvcview-2.0.6+debian/guvcview/config.c:243:47:  [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(!token || !value || strlen(token) < 1 || strlen(value) < 1)
data/guvcview-2.0.6+debian/guvcview/config.c:261:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(my_config.capture, value, 4);
data/guvcview-2.0.6+debian/guvcview/config.c:263:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(my_config.audio, value, 5);
data/guvcview-2.0.6+debian/guvcview/config.c:265:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(my_config.gui, value, 4);
data/guvcview-2.0.6+debian/guvcview/config.c:267:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(my_config.render, value, 4);
data/guvcview-2.0.6+debian/guvcview/config.c:269:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(my_config.video_codec, value, 4);
data/guvcview-2.0.6+debian/guvcview/config.c:271:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(my_config.audio_codec, value, 4);
data/guvcview-2.0.6+debian/guvcview/config.c:272:49:  [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).
		else if(strcmp(token, "profile_name") == 0 && strlen(value) > 2)
data/guvcview-2.0.6+debian/guvcview/config.c:286:48:  [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).
		else if(strcmp(token, "video_name") == 0  && strlen(value) > 2)
data/guvcview-2.0.6+debian/guvcview/config.c:298:48:  [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).
		else if(strcmp(token, "photo_name") == 0  && strlen(value) > 2)
data/guvcview-2.0.6+debian/guvcview/config.c:379:5:  [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(my_options->capture) > 3)
data/guvcview-2.0.6+debian/guvcview/config.c:380:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(my_config.capture, my_options->capture, 4);
data/guvcview-2.0.6+debian/guvcview/config.c:383:5:  [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(my_options->render) > 2)
data/guvcview-2.0.6+debian/guvcview/config.c:384:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(my_config.render, my_options->render, 4);
data/guvcview-2.0.6+debian/guvcview/config.c:387:5:  [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(my_options->gui) > 2)
data/guvcview-2.0.6+debian/guvcview/config.c:388:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(my_config.gui, my_options->gui, 4);
data/guvcview-2.0.6+debian/guvcview/config.c:391:5:  [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(my_options->audio) > 3)
data/guvcview-2.0.6+debian/guvcview/config.c:392:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(my_config.audio, my_options->audio, 5);
data/guvcview-2.0.6+debian/guvcview/config.c:399:5:  [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(my_options->format) > 2)
data/guvcview-2.0.6+debian/guvcview/config.c:406:5:  [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(my_options->video_codec) > 2)
data/guvcview-2.0.6+debian/guvcview/config.c:407:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(my_config.video_codec, my_options->video_codec, 4);
data/guvcview-2.0.6+debian/guvcview/config.c:410:5:  [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(my_options->audio_codec) > 2)
data/guvcview-2.0.6+debian/guvcview/config.c:411:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(my_config.audio_codec, my_options->audio_codec, 4);
data/guvcview-2.0.6+debian/guvcview/core_io.c:69:20:  [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(src == NULL || strlen(src) < 1)
data/guvcview-2.0.6+debian/guvcview/core_io.c:100:20:  [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(src == NULL || strlen(src) < 1)
data/guvcview-2.0.6+debian/guvcview/core_io.c:104:21:  [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).
	char *srcp = src + strlen(src);
data/guvcview-2.0.6+debian/guvcview/core_io.c:154:19:  [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).
	int size_dest =  strlen(dest);
data/guvcview-2.0.6+debian/guvcview/core_io.c:155:18:  [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).
	int size_str1 = strlen(str1);
data/guvcview-2.0.6+debian/guvcview/core_io.c:289:16:  [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).
	int strsize = strlen(filename);
data/guvcview-2.0.6+debian/guvcview/core_io.c:382:18:  [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).
	int noextsize = strlen(filename);
data/guvcview-2.0.6+debian/guvcview/core_io.c:395:14:  [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).
	int fsize = strlen(filename) + 7;
data/guvcview-2.0.6+debian/guvcview/core_io.c:479:18:  [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).
	int size_name = strlen(filename);
data/guvcview-2.0.6+debian/guvcview/core_io.c:481:18:  [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).
	int noextsize = strlen(filename);
data/guvcview-2.0.6+debian/guvcview/gui.c:153:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
		strncpy(my_config->video_codec, "raw", 4);
data/guvcview-2.0.6+debian/guvcview/gui.c:159:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(my_config->video_codec, codec_4cc, 4);
data/guvcview-2.0.6+debian/guvcview/gui.c:200:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(my_config->audio_codec, codec_name, 4);
data/guvcview-2.0.6+debian/guvcview/gui_gtk3.c:546:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
				strncpy(videodevice, v4l2core_get_device_sys_data(index)->device, 29);
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_callbacks.c:875:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(control->string, gtk_entry_get_text(GTK_ENTRY(entry)), control->control.maximum + 1);
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_callbacks.c:1146:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(videodevice, v4l2core_get_device_sys_data(index)->device, 29);
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_callbacks.c:1716:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(my_config->audio, "none", 5);
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_callbacks.c:1719:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(my_config->audio, "pulse", 5);
data/guvcview-2.0.6+debian/guvcview/gui_gtk3_callbacks.c:1722:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(my_config->audio, "port", 5);
data/guvcview-2.0.6+debian/guvcview/gui_qt5_callbacks.cpp:637:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(control->string, text_input.toStdString().c_str(), control->control.maximum);
data/guvcview-2.0.6+debian/guvcview/gui_qt5_callbacks.cpp:1364:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(my_config->audio, "none", 5);
data/guvcview-2.0.6+debian/guvcview/gui_qt5_callbacks.cpp:1367:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(my_config->audio, "pulse", 5);
data/guvcview-2.0.6+debian/guvcview/gui_qt5_callbacks.cpp:1370:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(my_config->audio, "port", 5);
data/guvcview-2.0.6+debian/guvcview/guvcview.c:199:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
		strncpy(my_config->gui, "qt5", 4);
data/guvcview-2.0.6+debian/guvcview/guvcview.c:203:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
		strncpy(my_config->gui, "none", 4);
data/guvcview-2.0.6+debian/guvcview/guvcview.c:213:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
		strncpy(my_config->gui, "gtk3", 4);
data/guvcview-2.0.6+debian/guvcview/guvcview.c:217:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
		strncpy(my_config->gui, "none", 4);
data/guvcview-2.0.6+debian/guvcview/options.c:304:8:  [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).
	while(strlen(opt_values[i].opt_long) > 0);
data/guvcview-2.0.6+debian/guvcview/options.c:329: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).
			  strlen(opt_values[i].opt_long);
data/guvcview-2.0.6+debian/guvcview/options.c:330: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(opt_values[i].opt_help_arg) > 0)
data/guvcview-2.0.6+debian/guvcview/options.c:331: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).
			len += strlen(opt_values[i].opt_help_arg) + 1; /*add =*/
data/guvcview-2.0.6+debian/guvcview/options.c:336:8:  [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).
	while(strlen(opt_values[i].opt_long) > 0);
data/guvcview-2.0.6+debian/guvcview/options.c:373:10:  [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).
		len += strlen(opt_values[i].opt_long) + 2;
data/guvcview-2.0.6+debian/guvcview/options.c:375: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(opt_values[i].opt_help_arg) > 0)
data/guvcview-2.0.6+debian/guvcview/options.c:377: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).
			len += strlen(opt_values[i].opt_help_arg) + 1;
data/guvcview-2.0.6+debian/guvcview/options.c:386: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(opt_values[i].opt_help) > 0)
data/guvcview-2.0.6+debian/guvcview/options.c:391:8:  [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).
	while(strlen(opt_values[i].opt_long) > 0);
data/guvcview-2.0.6+debian/guvcview/options.c:475:20:  [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).
				int str_size = strlen(optarg);
data/guvcview-2.0.6+debian/guvcview/options.c:477:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					strncpy(my_options.device, optarg, 29);
data/guvcview-2.0.6+debian/guvcview/options.c:489:20:  [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).
				int str_size = strlen(optarg);
data/guvcview-2.0.6+debian/guvcview/options.c:491:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					strncpy(my_options.capture, optarg, 4);
data/guvcview-2.0.6+debian/guvcview/options.c:518:20:  [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).
				int str_size = strlen(optarg);
data/guvcview-2.0.6+debian/guvcview/options.c:520:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					strncpy(my_options.format, optarg, 4);
data/guvcview-2.0.6+debian/guvcview/options.c:543:20:  [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).
				int str_size = strlen(optarg);
data/guvcview-2.0.6+debian/guvcview/options.c:545:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					strncpy(my_options.render, optarg, 4);
data/guvcview-2.0.6+debian/guvcview/options.c:550:20:  [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).
				int str_size = strlen(optarg);
data/guvcview-2.0.6+debian/guvcview/options.c:552:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					strncpy(my_options.render_flag, optarg, 4);
data/guvcview-2.0.6+debian/guvcview/options.c:574:20:  [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).
				int str_size = strlen(optarg);
data/guvcview-2.0.6+debian/guvcview/options.c:576:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					strncpy(my_options.gui, optarg, 4);
data/guvcview-2.0.6+debian/guvcview/options.c:582:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
				strncpy(my_options.audio, optarg, 5);
data/guvcview-2.0.6+debian/guvcview/options.c:590:20:  [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).
				int str_size = strlen(optarg);
data/guvcview-2.0.6+debian/guvcview/options.c:592:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					strncpy(my_options.audio_codec, optarg, 4);
data/guvcview-2.0.6+debian/guvcview/options.c:597:20:  [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).
				int str_size = strlen(optarg);
data/guvcview-2.0.6+debian/guvcview/options.c:599:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					strncpy(my_options.video_codec, optarg, 4);
data/guvcview-2.0.6+debian/guvcview/video_capture.c:878:17:  [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).
	int pathsize = strlen(path);
data/guvcview-2.0.6+debian/guvcview/video_capture.c:1199:20:  [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).
				int pathsize = strlen(path);
data/guvcview-2.0.6+debian/gview_audio/audio_portaudio.c:272:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
				strncpy(audio_ctx->list_devices[audio_ctx->num_input_dev-1].name, deviceInfo->name, 511);
data/guvcview-2.0.6+debian/gview_audio/audio_portaudio.c:273:5:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
				strncpy(audio_ctx->list_devices[audio_ctx->num_input_dev-1].description, deviceInfo->name, 255);
data/guvcview-2.0.6+debian/gview_audio/audio_pulseaudio.c:187:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(audio_ctx->list_devices[audio_ctx->num_input_dev-1].name,  l->name, 511);
data/guvcview-2.0.6+debian/gview_audio/audio_pulseaudio.c:188:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(audio_ctx->list_devices[audio_ctx->num_input_dev-1].description, l->description, 255);
data/guvcview-2.0.6+debian/gview_encoder/avi.c:564:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(stream->compressor, encoder_get_video_codec_4cc(codec_ind), 8);
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:266:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(video_defaults->compressor, "MJPG", 5);
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:268:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(video_defaults->mkv_codec, "V_MS/VFW/FOURCC", 25);
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:279:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(video_defaults->compressor, "H264", 5);
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:281:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(video_defaults->mkv_codec, "V_MPEG4/ISO/AVC", 25);
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:300:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(video_defaults->compressor, fourcc, 5);
data/guvcview-2.0.6+debian/gview_encoder/encoder.c:302:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120). Risk is low because the source is a
  constant string.
			strncpy(video_defaults->mkv_codec, "V_MS/VFW/FOURCC", 25);
data/guvcview-2.0.6+debian/gview_encoder/file_io.c:542:8:  [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(str) < len )
data/guvcview-2.0.6+debian/gview_encoder/file_io.c:544:9:  [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).
		len = strlen(str);
data/guvcview-2.0.6+debian/gview_encoder/matroska.c:213:50:  [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).
    mkv_put_ebml_binary(mkv_ctx, elementid, str, strlen(str));
data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c:222: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(strlen(str) > max) /*FIXME: should also check (minimum +N*step)*/
data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c:225:16:  [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).
									(int) strlen(str), max);
data/guvcview-2.0.6+debian/gview_v4l2core/control_profile.c:234: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).
								current->string = strndup(str, strlen(str)+1);
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c:949: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).
                        unsigned len = strlen(clist[i].string);
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c:952:7:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
						strncpy(ctrl->string, clist[i].string, max_len + 1);
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c:1082:6:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					strncpy(control->string, ctrl.string, ctrl.size);
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c:1151:20:  [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).
				unsigned len = strlen(current->string);
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c:1163:28:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					clist[count].string = strncpy(clist[count].string, current->string, max_len);
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c:1371:20:  [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).
				unsigned len = strlen(control->string);
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_controls.c:1383:20:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
					ctrl.string = strncpy(ctrl.string, control->string, max_len);
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_formats.c:135:16:  [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(!fourcc || strlen(fourcc) !=  4)
data/guvcview-2.0.6+debian/gview_v4l2core/v4l2_formats.c:608:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(vd->list_stream_formats[fmtind-1].description, (char *) fmt.description, 31);

ANALYSIS SUMMARY:

Hits = 244
Lines analyzed = 56331 in approximately 1.35 seconds (41795 lines/second)
Physical Source Lines of Code (SLOC) = 32192
Hits@level = [0] 903 [1] 107 [2] 125 [3]   5 [4]   7 [5]   0
Hits@level+ = [0+] 1147 [1+] 244 [2+] 137 [3+]  12 [4+]   7 [5+]   0
Hits/KSLOC@level+ = [0+] 35.63 [1+] 7.57952 [2+] 4.25572 [3+] 0.372763 [4+] 0.217445 [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.