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/vdr-plugin-games-0.6.3/bitmap.cpp
Examining data/vdr-plugin-games-0.6.3/bitmap.h
Examining data/vdr-plugin-games-0.6.3/display.h
Examining data/vdr-plugin-games-0.6.3/font.h
Examining data/vdr-plugin-games-0.6.3/screen.h
Examining data/vdr-plugin-games-0.6.3/text.cpp
Examining data/vdr-plugin-games-0.6.3/text.h
Examining data/vdr-plugin-games-0.6.3/minesweeper/minesweeper.h
Examining data/vdr-plugin-games-0.6.3/minesweeper/minesweeper.cpp
Examining data/vdr-plugin-games-0.6.3/snake/snake.cpp
Examining data/vdr-plugin-games-0.6.3/tetris/tetris.cpp
Examining data/vdr-plugin-games-0.6.3/tetris/tetris.h
Examining data/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp
Examining data/vdr-plugin-games-0.6.3/tron/tron.cpp
Examining data/vdr-plugin-games-0.6.3/display.cpp
Examining data/vdr-plugin-games-0.6.3/defines.h
Examining data/vdr-plugin-games-0.6.3/launcher.cpp
Examining data/vdr-plugin-games-0.6.3/main.cpp
Examining data/vdr-plugin-games-0.6.3/plugin.cpp
Examining data/vdr-plugin-games-0.6.3/screen.cpp

FINAL RESULTS:

data/vdr-plugin-games-0.6.3/defines.h:7:21:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
#define SRND()      srand(time(NULL))
data/vdr-plugin-games-0.6.3/display.cpp:42:1:  [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).
open(int x, int y, int w, int h, bool fr) {
data/vdr-plugin-games-0.6.3/display.cpp:48:12:  [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).
	if (!Scr::open(x, y, w, h)) {
data/vdr-plugin-games-0.6.3/display.cpp:235: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 txt[16];
data/vdr-plugin-games-0.6.3/display.cpp:243: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 txt[16];
data/vdr-plugin-games-0.6.3/display.cpp:251: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 txt[16];
data/vdr-plugin-games-0.6.3/display.h:8:5:  [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 open(int x, int y, int w, int h, bool frame=true);
data/vdr-plugin-games-0.6.3/launcher.cpp:34: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 *games[32];
data/vdr-plugin-games-0.6.3/main.cpp:36:10:  [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).
	game  = atoi(argv[1]);
data/vdr-plugin-games-0.6.3/main.cpp:37:10:  [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).
	size  = atoi(argv[2]);
data/vdr-plugin-games-0.6.3/main.cpp:38:10:  [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).
	skill = atoi(argv[3]);
data/vdr-plugin-games-0.6.3/minesweeper/minesweeper.cpp:39: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 field[16][12];
data/vdr-plugin-games-0.6.3/minesweeper/minesweeper.cpp:40: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 hidden[16][12];
data/vdr-plugin-games-0.6.3/minesweeper/minesweeper.cpp:268:7:  [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).
	Dpy::open(X, Y, W, H);
data/vdr-plugin-games-0.6.3/plugin.cpp:146:47:  [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).
	if      (!strcasecmp(Name, "OsdSize"))   s = atoi(Value);
data/vdr-plugin-games-0.6.3/plugin.cpp:147:47:  [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).
	else if (!strcasecmp(Name, "XPosition")) x = atoi(Value);
data/vdr-plugin-games-0.6.3/plugin.cpp:148:47:  [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).
	else if (!strcasecmp(Name, "YPosition")) y = atoi(Value);
data/vdr-plugin-games-0.6.3/plugin.cpp:149:47:  [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).
	else if (!strcasecmp(Name, "Skill"))     c = atoi(Value);
data/vdr-plugin-games-0.6.3/screen.cpp:148:1:  [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).
open(int x, int y, int w, int h) {
data/vdr-plugin-games-0.6.3/screen.h:6:5:  [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 open(int x, int y, int w, int h);
data/vdr-plugin-games-0.6.3/snake/snake.cpp:25: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 field[HEIGHT][WIDTH];
data/vdr-plugin-games-0.6.3/snake/snake.cpp:189:7:  [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).
	Dpy::open(X, Y, W, H);
data/vdr-plugin-games-0.6.3/tetris/tetris.cpp:24: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 field[HEIGHT][WIDTH];
data/vdr-plugin-games-0.6.3/tetris/tetris.cpp:25: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 piece[4][2];
data/vdr-plugin-games-0.6.3/tetris/tetris.cpp:190: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 tmp[4][2];
data/vdr-plugin-games-0.6.3/tetris/tetris.cpp:272:7:  [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).
	Dpy::open(X, Y, W, H);
data/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:29: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 field[3][3];
data/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:391: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 tmp[4];
data/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:432: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 tmp[4];
data/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:451: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 tmp[9];
data/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:499:7:  [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).
	Dpy::open(X, Y, W, H);
data/vdr-plugin-games-0.6.3/tron/tron.cpp:41: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 field[HEIGHT][WIDTH];
data/vdr-plugin-games-0.6.3/tron/tron.cpp:348:7:  [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).
	Dpy::open(X, Y, W, H);
data/vdr-plugin-games-0.6.3/main.cpp:75: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(5000); // 5 ms
data/vdr-plugin-games-0.6.3/minesweeper/minesweeper.cpp:285: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/vdr-plugin-games-0.6.3/minesweeper/minesweeper.cpp:295:19:  [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.
	while (!stopped) usleep(10000);
data/vdr-plugin-games-0.6.3/snake/snake.cpp:208: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+10000*(10-level));
data/vdr-plugin-games-0.6.3/snake/snake.cpp:226:19:  [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.
	while (!stopped) usleep(10000);
data/vdr-plugin-games-0.6.3/tetris/tetris.cpp:226: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(1000);
data/vdr-plugin-games-0.6.3/tetris/tetris.cpp:231: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(1000);
data/vdr-plugin-games-0.6.3/tetris/tetris.cpp:290:4:  [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(17000+8000*(10-level));
data/vdr-plugin-games-0.6.3/tetris/tetris.cpp:313:19:  [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.
	while (!stopped) usleep(10000);
data/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:121: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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:125:2:  [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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:129: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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:133:2:  [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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:136:2:  [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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:208: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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:214: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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:225: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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:231: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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:244: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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:255: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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:515:5:  [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(250000);
data/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:525: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/vdr-plugin-games-0.6.3/tictactoe/tictactoe.cpp:537:19:  [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.
	while (!stopped) usleep(10000);
data/vdr-plugin-games-0.6.3/tron/tron.cpp:365: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+6000*(10-level));
data/vdr-plugin-games-0.6.3/tron/tron.cpp:383:19:  [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.
	while (!stopped) usleep(10000);

ANALYSIS SUMMARY:

Hits = 58
Lines analyzed = 10273 in approximately 0.26 seconds (39568 lines/second)
Physical Source Lines of Code (SLOC) = 9885
Hits@level = [0]   7 [1]  25 [2]  32 [3]   1 [4]   0 [5]   0
Hits@level+ = [0+]  65 [1+]  58 [2+]  33 [3+]   1 [4+]   0 [5+]   0
Hits/KSLOC@level+ = [0+] 6.57562 [1+] 5.86748 [2+] 3.33839 [3+] 0.101163 [4+]   0 [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.