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/frotz-2.52+dfsg/src/blorb/blorb.h
Examining data/frotz-2.52+dfsg/src/blorb/blorblib.c
Examining data/frotz-2.52+dfsg/src/blorb/blorblow.h
Examining data/frotz-2.52+dfsg/src/common/buffer.c
Examining data/frotz-2.52+dfsg/src/common/err.c
Examining data/frotz-2.52+dfsg/src/common/fastmem.c
Examining data/frotz-2.52+dfsg/src/common/files.c
Examining data/frotz-2.52+dfsg/src/common/frotz.h
Examining data/frotz-2.52+dfsg/src/common/getopt.c
Examining data/frotz-2.52+dfsg/src/common/hotkey.c
Examining data/frotz-2.52+dfsg/src/common/input.c
Examining data/frotz-2.52+dfsg/src/common/main.c
Examining data/frotz-2.52+dfsg/src/common/math.c
Examining data/frotz-2.52+dfsg/src/common/missing.c
Examining data/frotz-2.52+dfsg/src/common/missing.h
Examining data/frotz-2.52+dfsg/src/common/object.c
Examining data/frotz-2.52+dfsg/src/common/process.c
Examining data/frotz-2.52+dfsg/src/common/quetzal.c
Examining data/frotz-2.52+dfsg/src/common/random.c
Examining data/frotz-2.52+dfsg/src/common/redirect.c
Examining data/frotz-2.52+dfsg/src/common/screen.c
Examining data/frotz-2.52+dfsg/src/common/setup.h
Examining data/frotz-2.52+dfsg/src/common/sound.c
Examining data/frotz-2.52+dfsg/src/common/stream.c
Examining data/frotz-2.52+dfsg/src/common/table.c
Examining data/frotz-2.52+dfsg/src/common/text.c
Examining data/frotz-2.52+dfsg/src/common/unused.h
Examining data/frotz-2.52+dfsg/src/common/variable.c
Examining data/frotz-2.52+dfsg/src/curses/ux_audio.c
Examining data/frotz-2.52+dfsg/src/curses/ux_audio.h
Examining data/frotz-2.52+dfsg/src/curses/ux_audio_none.c
Examining data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c
Examining data/frotz-2.52+dfsg/src/curses/ux_blorb.c
Examining data/frotz-2.52+dfsg/src/curses/ux_blorb.h
Examining data/frotz-2.52+dfsg/src/curses/ux_frotz.h
Examining data/frotz-2.52+dfsg/src/curses/ux_init.c
Examining data/frotz-2.52+dfsg/src/curses/ux_input.c
Examining data/frotz-2.52+dfsg/src/curses/ux_pic.c
Examining data/frotz-2.52+dfsg/src/curses/ux_screen.c
Examining data/frotz-2.52+dfsg/src/curses/ux_sema.h
Examining data/frotz-2.52+dfsg/src/curses/ux_setup.h
Examining data/frotz-2.52+dfsg/src/curses/ux_text.c
Examining data/frotz-2.52+dfsg/src/dos/bcblorb.c
Examining data/frotz-2.52+dfsg/src/dos/bcblorb.h
Examining data/frotz-2.52+dfsg/src/dos/bcfrotz.h
Examining data/frotz-2.52+dfsg/src/dos/bchash.h
Examining data/frotz-2.52+dfsg/src/dos/bcinit.c
Examining data/frotz-2.52+dfsg/src/dos/bcinput.c
Examining data/frotz-2.52+dfsg/src/dos/bcmouse.c
Examining data/frotz-2.52+dfsg/src/dos/bcpic.c
Examining data/frotz-2.52+dfsg/src/dos/bcsample.c
Examining data/frotz-2.52+dfsg/src/dos/bcscreen.c
Examining data/frotz-2.52+dfsg/src/dos/bctext.c
Examining data/frotz-2.52+dfsg/src/dos/blorb.h
Examining data/frotz-2.52+dfsg/src/dos/blorblow.h
Examining data/frotz-2.52+dfsg/src/dos/fontdata.h
Examining data/frotz-2.52+dfsg/src/dumb/dblorb.c
Examining data/frotz-2.52+dfsg/src/dumb/dblorb.h
Examining data/frotz-2.52+dfsg/src/dumb/dfrotz.h
Examining data/frotz-2.52+dfsg/src/dumb/dinit.c
Examining data/frotz-2.52+dfsg/src/dumb/dinput.c
Examining data/frotz-2.52+dfsg/src/dumb/doutput.c
Examining data/frotz-2.52+dfsg/src/dumb/dpic.c
Examining data/frotz-2.52+dfsg/src/sdl/generic.c
Examining data/frotz-2.52+dfsg/src/sdl/generic.h
Examining data/frotz-2.52+dfsg/src/sdl/sf_deffont.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_font3.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_fonts.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_ftype.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_msg_en.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_sig.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_sound.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_util.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_frotz.h
Examining data/frotz-2.52+dfsg/src/sdl/sf_resource.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_video.c
Examining data/frotz-2.52+dfsg/src/sdl/sf_images.c

FINAL RESULTS:

data/frotz-2.52+dfsg/src/dos/bcinit.c:385: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(filename, story_name);
data/frotz-2.52+dfsg/src/dos/bcinit.c:387:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat(filename, extension);
data/frotz-2.52+dfsg/src/dos/bcinit.c:897:4:  [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(bp, name);
data/frotz-2.52+dfsg/src/dos/bcinput.c:886: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(file_name, default_name);
data/frotz-2.52+dfsg/src/dos/bcinput.c:888:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat(file_name, extension);
data/frotz-2.52+dfsg/src/dos/bcinput.c:899: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(file_name, f_setup.restricted_path);
data/frotz-2.52+dfsg/src/dos/bcinput.c:903:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat(file_name, tempname);
data/frotz-2.52+dfsg/src/dos/bcpic.c:94:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(fname, f_setup.story_name);
data/frotz-2.52+dfsg/src/dos/bcpic.c:95:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(fname, extension);
data/frotz-2.52+dfsg/src/dumb/dinput.c:512:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			sprintf(prompt, "Please enter a filename [%s]: ", tempname);
data/frotz-2.52+dfsg/src/dumb/dinput.c:514:4:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
			sprintf(prompt, "Please enter a filename [%s]: ", default_name);
data/frotz-2.52+dfsg/src/sdl/generic.c:274:8:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
	len = vsnprintf(buf, sizeof(buf), s, va);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:996:7:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
		if (access(buf, F_OK) == 0)
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:388:2:  [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(filename, def);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:392: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(lastdir, filename);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:393: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(filename, pp + 1);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:402:2:  [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(buffer, filt);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:406:2:  [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(pattern, buffer);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:483:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(buffer, filt);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:508:4:  [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(buffer, lastdir);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:509:4:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
			strcat(buffer, filename);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:511:28:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
			if ((existing == 0) && (access(buffer, F_OK) == 0))
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:529: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(buffer, lastdir);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:530:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat(buffer, filename);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:712: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(resdend, p);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:858: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(buffer, s);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:990:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat(lastdir, e->value);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:997:2:  [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(filename, selected->value);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:743:2:  [4] (format) vfprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
	vfprintf(stderr, s, m);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:857:2:  [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(buf, ResDir);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:858:2:  [4] (format) sprintf:
  Potential format string problem (CWE-134). Make format string constant.
	sprintf(buf + strlen(buf), tpl, num);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:1089:2:  [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(buf, ResDir);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:1090:2:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
	strcat(buf, l->name);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:203:2:  [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(info_header, VERSION);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:570:2:  [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(buf, f_setup.story_name);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:573:3:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
		sprintf(buf + len, "%03d%s", number++, ext);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:574:7:  [4] (race) access:
  This usually indicates a security flaw. If an attacker can change anything
  along the path between the call to access() and the file's actual use
  (e.g., by moving files), the attacker can exploit the race condition
  (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid())
  and try to open the file directly.
		if (access(buf, F_OK))
data/frotz-2.52+dfsg/src/sdl/sf_util.c:590:2:  [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(buf, f_setup.story_name);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:592:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(buf + len, "%04d%02d%02d%02d%02d%s",
data/frotz-2.52+dfsg/src/sdl/sf_util.c:716: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(file_name, default_name);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:718:3:  [4] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused).
		strcat(file_name, extension);
data/frotz-2.52+dfsg/src/sdl/sf_video.c:503:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(banner, "SDL Frotz v%s - %s (z%d)",
data/frotz-2.52+dfsg/src/curses/ux_init.c:222:14:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if ((home = getenv(HOMEDIR)) == NULL) {
data/frotz-2.52+dfsg/src/curses/ux_init.c:452:6:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if (getenv("ESCDELAY") == NULL)
data/frotz-2.52+dfsg/src/curses/ux_init.c:653:12:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if ( (p = getenv(PATH1) ) == NULL)
data/frotz-2.52+dfsg/src/curses/ux_init.c:654:7:  [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.
		p = getenv(PATH2);
data/frotz-2.52+dfsg/src/dos/bcinit.c:888:11:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if ((p = getenv("ZCODE_PATH")) == NULL)
data/frotz-2.52+dfsg/src/dos/bcinit.c:889:7:  [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.
		p = getenv("INFOCOM_PATH");
data/frotz-2.52+dfsg/src/dos/bcsample.c:131:18:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if ((settings = getenv("BLASTER")) == NULL)
data/frotz-2.52+dfsg/src/sdl/sf_ftype.c:314:10:  [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.
		fenv = getenv("FONTS");
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:208:12:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
	if ( (p = getenv(PATH1) ) == NULL)
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:209:7:  [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.
		p = getenv(PATH2);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:457:19:  [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.
		myhome = strdup(getenv(HOMEDIR));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:829:19:  [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.
	homedir = strdup(getenv(HOMEDIR));
data/frotz-2.52+dfsg/src/blorb/blorb.h:139: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 serialnum[6]; /* Bytes $12-17 of header. */
data/frotz-2.52+dfsg/src/blorb/blorblib.c:44:18:  [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.
        unsigned char ch[4];
data/frotz-2.52+dfsg/src/blorb/blorblib.c:514:12:  [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 buf[5];
data/frotz-2.52+dfsg/src/common/fastmem.c:71:1:  [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 auxilary_name[MAX_FILE_NAME + 1] = DEFAULT_AUXILARY_NAME;
data/frotz-2.52+dfsg/src/common/fastmem.c:730: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 default_name[MAX_FILE_NAME + 1];
data/frotz-2.52+dfsg/src/common/fastmem.c:747:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((gfp = fopen (new_name, "rb")) == NULL)
data/frotz-2.52+dfsg/src/common/fastmem.c:770:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((gfp = fopen(new_name, "rb")) == NULL)
data/frotz-2.52+dfsg/src/common/fastmem.c:957: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 default_name[MAX_FILE_NAME + 1];
data/frotz-2.52+dfsg/src/common/fastmem.c:973:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((gfp = fopen(new_name, "wb")) == NULL)
data/frotz-2.52+dfsg/src/common/fastmem.c:999:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((gfp = fopen(new_name, "wb")) == NULL)
data/frotz-2.52+dfsg/src/common/files.c:81:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	if ((sfp = fopen (f_setup.script_name, "r+t")) != NULL ||
data/frotz-2.52+dfsg/src/common/files.c:82:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	    (sfp = fopen(f_setup.script_name, "w+t")) != NULL) {
data/frotz-2.52+dfsg/src/common/files.c:308:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((rfp = fopen(new_name, "wt")) != NULL)
data/frotz-2.52+dfsg/src/common/files.c:421:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((pfp = fopen(new_name, "rt")) != NULL) {
data/frotz-2.52+dfsg/src/common/text.c:1019:24:  [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 const unsigned char tolower_basic_latin[0x100] = {
data/frotz-2.52+dfsg/src/common/text.c:1053:24:  [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 const unsigned char tolower_latin_extended_a[0x80] = {
data/frotz-2.52+dfsg/src/common/text.c:1071:24:  [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 const unsigned char tolower_greek[0x50] = {
data/frotz-2.52+dfsg/src/common/text.c:1083:24:  [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 const unsigned char tolower_cyrillic[0x60] = {
data/frotz-2.52+dfsg/src/curses/ux_audio.c:298: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(rsmp->input, block, channels*smps*sizeof(float));
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:93:11:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	dsp_fd = open(SOUND_DEV, O_WRONLY);
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:125:14:  [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).
		mixer_fd = open("/dev/mixer", O_RDWR);
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:219:2:  [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(filename, "%.*ssound/%.*s%02d.snd",
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:224: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).
	samples = fopen(filename, "r");
data/frotz-2.52+dfsg/src/curses/ux_blorb.c:99: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(mystring, filename, MAX(len1, len2) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_blorb.c:184: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 mybuf[4];
data/frotz-2.52+dfsg/src/curses/ux_frotz.h:76: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.
extern char stripped_story_name[FILENAME_MAX+1];
data/frotz-2.52+dfsg/src/curses/ux_frotz.h:77: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.
extern char semi_stripped_story_name[FILENAME_MAX+1];
data/frotz-2.52+dfsg/src/curses/ux_init.c:205: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 configfile[FILENAME_MAX + 1];
data/frotz-2.52+dfsg/src/curses/ux_init.c:280:37:  [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).
		case 'c': f_setup.context_lines = atoi(zoptarg); break;
data/frotz-2.52+dfsg/src/curses/ux_init.c:295:37:  [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).
		case 'h': u_setup.screen_height = atoi(zoptarg); break;
data/frotz-2.52+dfsg/src/curses/ux_init.c:297:42:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		case 'I': f_setup.interpreter_number = atoi(zoptarg); break;
data/frotz-2.52+dfsg/src/curses/ux_init.c:298:35:  [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).
		case 'l': f_setup.left_margin = atoi(zoptarg); break;
data/frotz-2.52+dfsg/src/curses/ux_init.c:308:36:  [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).
		case 'r': f_setup.right_margin = atoi(zoptarg); break;
data/frotz-2.52+dfsg/src/curses/ux_init.c:310:35:  [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).
		case 's': u_setup.random_seed = atoi(zoptarg); break;
data/frotz-2.52+dfsg/src/curses/ux_init.c:311:35:  [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).
		case 'S': f_setup.script_cols = atoi(zoptarg); break;
data/frotz-2.52+dfsg/src/curses/ux_init.c:313:34:  [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).
		case 'u': f_setup.undo_slots = atoi(zoptarg); break;
data/frotz-2.52+dfsg/src/curses/ux_init.c:315:36:  [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).
		case 'w': u_setup.screen_width = atoi(zoptarg); break;
data/frotz-2.52+dfsg/src/curses/ux_init.c:318: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).
			f_setup.err_report_mode = atoi(zoptarg);
data/frotz-2.52+dfsg/src/curses/ux_init.c:356: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(f_setup.script_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SCRIPT)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:360: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(f_setup.command_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_COMMAND)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:365: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(f_setup.save_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:369: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(f_setup.save_name, f_setup.tmp_save_name, (strlen(f_setup.tmp_save_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:374: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(f_setup.aux_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_AUX)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:642: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(name, mode)))
data/frotz-2.52+dfsg/src/curses/ux_init.c:794: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(bp, name, strlen(name));
data/frotz-2.52+dfsg/src/curses/ux_init.c:799:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((fp = fopen(buf, mode)) != NULL) {
data/frotz-2.52+dfsg/src/curses/ux_init.c:832: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	varname[LINELEN + 1];
data/frotz-2.52+dfsg/src/curses/ux_init.c:833: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	value[LINELEN + 1];
data/frotz-2.52+dfsg/src/curses/ux_init.c:841: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(configfile, "r")) == NULL)
data/frotz-2.52+dfsg/src/curses/ux_init.c:925: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).
			f_setup.context_lines = atoi(value);
data/frotz-2.52+dfsg/src/curses/ux_init.c:928: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).
			u_setup.screen_height = atoi(value);
data/frotz-2.52+dfsg/src/curses/ux_init.c:931:26:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			f_setup.left_margin = atoi(value);
data/frotz-2.52+dfsg/src/curses/ux_init.c:934:27:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			f_setup.right_margin = atoi(value);
data/frotz-2.52+dfsg/src/curses/ux_init.c:937:26:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			u_setup.random_seed = atoi(value);
data/frotz-2.52+dfsg/src/curses/ux_init.c:940:26:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			f_setup.script_cols = atoi(value);
data/frotz-2.52+dfsg/src/curses/ux_init.c:943:25:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			f_setup.undo_slots = atoi(value);
data/frotz-2.52+dfsg/src/curses/ux_init.c:946:27:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			u_setup.screen_width = atoi(value);
data/frotz-2.52+dfsg/src/curses/ux_init.c:958: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(f_setup.zcode_path, value, sz);
data/frotz-2.52+dfsg/src/curses/ux_input.c:966: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 path_separator[2];
data/frotz-2.52+dfsg/src/curses/ux_input.c:967: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 file_name[FILENAME_MAX + 1];
data/frotz-2.52+dfsg/src/curses/ux_input.c:1093: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).
	    && ((fp = fopen(file_name, "rb")) != NULL)) {
data/frotz-2.52+dfsg/src/curses/ux_pic.c:88:11:  [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.
	unsigned char png_magic[8] = {0x89, 0x50, 0x4E, 0x47, 0x0D, 0x0A, 0x1A, 0x0A};
data/frotz-2.52+dfsg/src/curses/ux_pic.c:90:11:  [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.
	unsigned char jpg_magic[3]	  = {0xFF, 0xD8, 0xFF};
data/frotz-2.52+dfsg/src/curses/ux_pic.c:91:11:  [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.
	unsigned char jfif_name[5]	  = {'J', 'F', 'I', 'F', 0x00};
data/frotz-2.52+dfsg/src/dos/bcblorb.c:39:12:  [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.
		unsigned char ch[4];
data/frotz-2.52+dfsg/src/dos/bcblorb.c:558:9:  [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 buf[5];
data/frotz-2.52+dfsg/src/dos/bcinit.c:418: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 stripped_story_name[10];
data/frotz-2.52+dfsg/src/dos/bcinit.c:883:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[MAX_FILE_NAME + 1];
data/frotz-2.52+dfsg/src/dos/bcinit.c:886: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(name, mode)) != NULL)
data/frotz-2.52+dfsg/src/dos/bcinit.c:898:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
			if ((fp = fopen(buf, mode)) != NULL)
data/frotz-2.52+dfsg/src/dos/bcinit.c:927:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fp = fopen(blorb_file, "rb");
data/frotz-2.52+dfsg/src/dos/bcinit.c:930:8:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		fp = fopen(f_setup.story_file, "rb");
data/frotz-2.52+dfsg/src/dos/bcinit.c:934:9:  [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).
	return fopen(f_setup.story_file, "rb");
data/frotz-2.52+dfsg/src/dos/bcinit.c:950:20:  [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 ((blorbfile = fopen(blorb_file, "rb")) == NULL)
data/frotz-2.52+dfsg/src/dos/bcinput.c:859: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 file_name[FILENAME_MAX + 1];
data/frotz-2.52+dfsg/src/dos/bcinput.c:914: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(file_name, "rb")) == NULL)
data/frotz-2.52+dfsg/src/dos/bcpic.c: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 fname[MAX_FILE_NAME + 1];
data/frotz-2.52+dfsg/src/dos/bcpic.c:83:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char extension[4 + 1];
data/frotz-2.52+dfsg/src/dos/bcpic.c:93:2:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
	strcpy(fname, "graphics/");
data/frotz-2.52+dfsg/src/dos/bcpic.c:98:14:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	if ((file = fopen(fname, "rb")) == NULL)
data/frotz-2.52+dfsg/src/dos/bcsample.c:268: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 sample_name[MAX_FILE_NAME + 1];
data/frotz-2.52+dfsg/src/dos/bcsample.c:269: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 numstr[2];
data/frotz-2.52+dfsg/src/dos/bcsample.c:273:3:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
		strcpy(sample_name, "sound/");
data/frotz-2.52+dfsg/src/dos/bcsample.c:283:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((fp = fopen(sample_name, "rb")) == NULL)
data/frotz-2.52+dfsg/src/dos/blorb.h:109: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 serialnum[6];	/* Bytes $12-17 of header. */
data/frotz-2.52+dfsg/src/dumb/dblorb.c:68: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, "rb")) == NULL)
data/frotz-2.52+dfsg/src/dumb/dblorb.c:86: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(mystring, filename, MAX(len1, len2) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dblorb.c:93:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((fp = fopen(mystring, "rb")) == NULL) {
data/frotz-2.52+dfsg/src/dumb/dblorb.c:97:15:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
			if (!(fp = fopen(mystring, "rb")))
data/frotz-2.52+dfsg/src/dumb/dblorb.c:142: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 mybuf[4];
data/frotz-2.52+dfsg/src/dumb/dinit.c:107:23:  [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).
			user_text_height = atoi(zoptarg);
data/frotz-2.52+dfsg/src/dumb/dinit.c:113:33:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			f_setup.interpreter_number = atoi(zoptarg);
data/frotz-2.52+dfsg/src/dumb/dinit.c:141:23:  [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).
			user_random_seed = atoi(zoptarg);
data/frotz-2.52+dfsg/src/dumb/dinit.c:144:26:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			f_setup.script_cols = atoi(zoptarg);
data/frotz-2.52+dfsg/src/dumb/dinit.c:150:25:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			f_setup.undo_slots = atoi(zoptarg);
data/frotz-2.52+dfsg/src/dumb/dinit.c:157:22:  [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).
			user_text_width = atoi(zoptarg);
data/frotz-2.52+dfsg/src/dumb/dinit.c:163: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).
			f_setup.err_report_mode = atoi(zoptarg);
data/frotz-2.52+dfsg/src/dumb/dinit.c:226:6:  [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(f_setup.script_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SCRIPT)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:232: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(f_setup.command_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_COMMAND)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:238: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(f_setup.save_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:243: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(f_setup.save_name, f_setup.tmp_save_name, (strlen(f_setup.tmp_save_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:249: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(f_setup.aux_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_AUX)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:334: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(f_setup.story_file, "rb");
data/frotz-2.52+dfsg/src/dumb/dinit.c:342:9:  [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).
	return fopen(f_setup.story_file, "rb");
data/frotz-2.52+dfsg/src/dumb/dinput.c:269:19:  [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).
				int elapsed = atoi(&command[1]);
data/frotz-2.52+dfsg/src/dumb/dinput.c:334: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 read_key_buffer[INPUT_BUFFER_SIZE];
data/frotz-2.52+dfsg/src/dumb/dinput.c:337: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 read_line_buffer[INPUT_BUFFER_SIZE];
data/frotz-2.52+dfsg/src/dumb/dinput.c:487: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 file_name[FILENAME_MAX + 1];
data/frotz-2.52+dfsg/src/dumb/dinput.c:488: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 fullpath[INPUT_BUFFER_SIZE], prompt[INPUT_BUFFER_SIZE];
data/frotz-2.52+dfsg/src/dumb/dinput.c:492: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 path_separator[2];
data/frotz-2.52+dfsg/src/dumb/dinput.c:551:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		&& ((fp = fopen(file_name, "rb")) != NULL)) {
data/frotz-2.52+dfsg/src/dumb/dinput.c:564:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char buf[INPUT_BUFFER_SIZE];
data/frotz-2.52+dfsg/src/dumb/doutput.c:43: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 frotz_to_dumb [256];
data/frotz-2.52+dfsg/src/dumb/doutput.c:92: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 rv_blank_str[5] = {' ', 0, 0, 0, 0};
data/frotz-2.52+dfsg/src/dumb/doutput.c:348: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 s[4];
data/frotz-2.52+dfsg/src/dumb/doutput.c:349:4:  [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(s, "%02d", (row + 1) % 100);
data/frotz-2.52+dfsg/src/dumb/doutput.c:779: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 changed_rows[0x100];
data/frotz-2.52+dfsg/src/dumb/doutput.c:893:27:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
			case 'h': hide_lines = atoi(&setting[2]); break;
data/frotz-2.52+dfsg/src/dumb/dpic.c:62:11:  [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.
	unsigned char png_magic[8]	= {0x89, 0x50, 0x4E, 0x47, 0x0D, 0x0A, 0x1A, 0x0A};
data/frotz-2.52+dfsg/src/dumb/dpic.c:64:11:  [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.
	unsigned char jpg_magic[3]	= {0xFF, 0xD8, 0xFF};
data/frotz-2.52+dfsg/src/dumb/dpic.c:65:11:  [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.
	unsigned char jfif_name[5]	= {'J', 'F', 'I', 'F', 0x00};
data/frotz-2.52+dfsg/src/sdl/generic.c:51: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 mybuf[4];
data/frotz-2.52+dfsg/src/sdl/generic.c:110: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(mystring, filename, MAX(len1, len2) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/generic.c:268:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[1024];
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:38:1:  [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 *m_fontfiles[9];
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:42: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 s[1026];
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:111:12:  [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).
			nprop = atoi(p);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:130:14:  [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).
			defchar = atoi(p);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:132:13:  [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).
			ascent = atoi(p);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:134:14:  [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).
			descent = atoi(p);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:141:14:  [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).
				nchars = atoi(p);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:157:9:  [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).
				k = atoi(p);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:231: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).
					i = atoi(p);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:241:17:  [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).
					    dwid = atoi(p);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:409:6:  [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).
	f = fopen(fname, "rb");
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:814:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[FILENAME_MAX];
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:824: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(at + 1);
data/frotz-2.52+dfsg/src/sdl/sf_frotz.h:91: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.
extern char *m_fontfiles[9];
data/frotz-2.52+dfsg/src/sdl/sf_ftype.c:296:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[FILENAME_MAX], *fn, *at, *fenv;
data/frotz-2.52+dfsg/src/sdl/sf_ftype.c:302: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(at + 1);
data/frotz-2.52+dfsg/src/sdl/sf_images.c:256: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 buffer[JMSG_LENGTH_MAX];
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:43: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 buffer[512];
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:44: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 lastdir[FILENAME_MAX] = "";
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:45: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 filename[FILENAME_MAX];
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:46: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 pattern[64];
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:400:3:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
		strcpy(lastdir, "./");
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:482:2:  [2] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused). Risk is low because the source is a constant string.
	strcpy(buffer, "Filter: ");
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:641: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 cwd[FILENAME_MAX], *p;
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:169: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(bp, name, strlen(name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:171:13:  [2] (misc) fopen:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		if ((fp = fopen(buf, mode)) != NULL) {
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:198: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(name, mode)))
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:854: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 *tpl, buf[MAX_FILE_NAME + 1];
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:859:6:  [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).
	f = fopen(buf, "rb");
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:1008: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).
	p_num = atoi(p);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:1032: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 s[256];
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:1034:6:  [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).
	f = fopen(m_reslist_file, "r");
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:1075:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char buf[MAX_FILE_NAME + 1];
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:1092:6:  [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).
	f = fopen(buf, "rb");
data/frotz-2.52+dfsg/src/sdl/sf_util.c:278: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).
			num = atoi(zoptarg);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:453: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(f_setup.script_name, f_setup.story_name, strlen(f_setup.story_name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:459: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(f_setup.command_name, f_setup.story_name, strlen(f_setup.story_name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:466: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(f_setup.save_name, f_setup.story_name, strlen(f_setup.story_name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:472: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(f_setup.save_name, f_setup.tmp_save_name, strlen(f_setup.tmp_save_name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:479: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(f_setup.aux_name, f_setup.story_name, strlen(f_setup.story_name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:565: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 buf[FILENAME_MAX];
data/frotz-2.52+dfsg/src/sdl/sf_util.c:628: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 file_name[FILENAME_MAX + 1];
data/frotz-2.52+dfsg/src/sdl/sf_util.c:728: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(file_name, "rb")) == NULL)
data/frotz-2.52+dfsg/src/sdl/sf_util.c:834:6:  [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).
	f = fopen(fn, "rb");
data/frotz-2.52+dfsg/src/sdl/sf_util.c:836: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).
		f = fopen(my_fn, "rb");
data/frotz-2.52+dfsg/src/sdl/sf_util.c:928: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).
			def = atoi(p);
data/frotz-2.52+dfsg/src/sdl/sf_video.c:32: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 banner[256];
data/frotz-2.52+dfsg/src/common/fastmem.c:711:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
			strncat(default_name, EXT_AUX, length - len - 1);
data/frotz-2.52+dfsg/src/common/fastmem.c:714:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(default_name, f_setup.aux_name, length - 1);
data/frotz-2.52+dfsg/src/common/fastmem.c:1114:15:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		checksum += fgetc(story_fp);
data/frotz-2.52+dfsg/src/common/files.c:454:11:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if ((c = fgetc(pfp)) == '[') {
data/frotz-2.52+dfsg/src/common/files.c:458:16:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		while ((c2 = fgetc(pfp)) != EOF && c2 >= '0' && c2 <= '9')
data/frotz-2.52+dfsg/src/common/files.c:509:6:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (fgetc(pfp) != '\n') {
data/frotz-2.52+dfsg/src/common/files.c:535:6:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if (fgetc(pfp) != '\n') {
data/frotz-2.52+dfsg/src/common/quetzal.c:48:15:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
#define get_c fgetc
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:209: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).
	filename = malloc(strlen(f_setup.story_name) + 10);
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:217:42:  [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).
	namelen = (dotpos ? dotpos - basename : strlen(basename));
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:230:2:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	fgetc(samples); fgetc(samples); fgetc(samples); fgetc(samples);
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:230:18:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	fgetc(samples); fgetc(samples); fgetc(samples); fgetc(samples);
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:230:34:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	fgetc(samples); fgetc(samples); fgetc(samples); fgetc(samples);
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:230:50:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	fgetc(samples); fgetc(samples); fgetc(samples); fgetc(samples);
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:231:16:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	sample_rate = fgetc(samples) << 8;
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:232:17:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	sample_rate |= fgetc(samples);
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:233:2:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	fgetc(samples); fgetc(samples);
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:233:18:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	fgetc(samples); fgetc(samples);
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:234:17:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	sound_length = fgetc(samples) << 8;
data/frotz-2.52+dfsg/src/curses/ux_audio_oss.c:235:18:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	sound_length |= fgetc(samples);
data/frotz-2.52+dfsg/src/curses/ux_blorb.c:93: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).
		len1 = strlen(filename) + strlen(EXT_BLORB);
data/frotz-2.52+dfsg/src/curses/ux_blorb.c:93:29:  [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).
		len1 = strlen(filename) + strlen(EXT_BLORB);
data/frotz-2.52+dfsg/src/curses/ux_blorb.c:94: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).
		len2 = strlen(filename) + strlen(EXT_BLORB3);
data/frotz-2.52+dfsg/src/curses/ux_blorb.c:94:29:  [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).
		len2 = strlen(filename) + strlen(EXT_BLORB3);
data/frotz-2.52+dfsg/src/curses/ux_blorb.c:103:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
			strncat(mystring, EXT_BLORB, len1);
data/frotz-2.52+dfsg/src/curses/ux_blorb.c:111:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
			strncat(mystring, EXT_BLORB3, len2);
data/frotz-2.52+dfsg/src/curses/ux_init.c:255:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(configfile, home, FILENAME_MAX);
data/frotz-2.52+dfsg/src/curses/ux_init.c:256:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant character.
	strncat(configfile, "/", 2);
data/frotz-2.52+dfsg/src/curses/ux_init.c:258:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(configfile, USER_CONFIG, strlen(USER_CONFIG) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:258:35:  [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).
	strncat(configfile, USER_CONFIG, strlen(USER_CONFIG) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:260:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(configfile, CONFIG_DIR, FILENAME_MAX);
data/frotz-2.52+dfsg/src/curses/ux_init.c:261:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant character.
		strncat(configfile, "/", 2);    /* added by DJP */
data/frotz-2.52+dfsg/src/curses/ux_init.c:262:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat(configfile, MASTER_CONFIG, FILENAME_MAX-10);
data/frotz-2.52+dfsg/src/curses/ux_init.c:355:32:  [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).
	f_setup.script_name = malloc((strlen(f_setup.story_name) + strlen(EXT_SCRIPT)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:355:61:  [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).
	f_setup.script_name = malloc((strlen(f_setup.story_name) + strlen(EXT_SCRIPT)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:356:51:  [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).
	memcpy(f_setup.script_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SCRIPT)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:356:80:  [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).
	memcpy(f_setup.script_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SCRIPT)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:357:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(f_setup.script_name, EXT_SCRIPT, strlen(EXT_SCRIPT) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:357:43:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	strncat(f_setup.script_name, EXT_SCRIPT, strlen(EXT_SCRIPT) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:359:33:  [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).
	f_setup.command_name = malloc((strlen(f_setup.story_name) + strlen(EXT_COMMAND)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:359:62:  [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).
	f_setup.command_name = malloc((strlen(f_setup.story_name) + strlen(EXT_COMMAND)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:360:52:  [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).
	memcpy(f_setup.command_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_COMMAND)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:360:81:  [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).
	memcpy(f_setup.command_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_COMMAND)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:361:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(f_setup.command_name, EXT_COMMAND, strlen(EXT_COMMAND) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:361:45:  [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).
	strncat(f_setup.command_name, EXT_COMMAND, strlen(EXT_COMMAND) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:364:31:  [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).
		f_setup.save_name = malloc((strlen(f_setup.story_name) + strlen(EXT_SAVE)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:364:60:  [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).
		f_setup.save_name = malloc((strlen(f_setup.story_name) + strlen(EXT_SAVE)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:365: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).
		memcpy(f_setup.save_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:365:79:  [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).
		memcpy(f_setup.save_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:366:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat(f_setup.save_name, EXT_SAVE, strlen(EXT_SAVE) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:366: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).
		strncat(f_setup.save_name, EXT_SAVE, strlen(EXT_SAVE) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:368:31:  [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).
		f_setup.save_name = malloc((strlen(f_setup.tmp_save_name) + strlen(EXT_SAVE)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:368:63:  [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).
		f_setup.save_name = malloc((strlen(f_setup.tmp_save_name) + strlen(EXT_SAVE)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:369:53:  [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).
		memcpy(f_setup.save_name, f_setup.tmp_save_name, (strlen(f_setup.tmp_save_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:369:85:  [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).
		memcpy(f_setup.save_name, f_setup.tmp_save_name, (strlen(f_setup.tmp_save_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:373:29:  [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).
	f_setup.aux_name = malloc((strlen(f_setup.story_name) + strlen(EXT_AUX)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:373:58:  [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).
	f_setup.aux_name = malloc((strlen(f_setup.story_name) + strlen(EXT_AUX)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:374: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).
	memcpy(f_setup.aux_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_AUX)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:374:77:  [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).
	memcpy(f_setup.aux_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_AUX)) * sizeof(char));
data/frotz-2.52+dfsg/src/curses/ux_init.c:375:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(f_setup.aux_name, EXT_AUX, strlen(EXT_AUX) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:375:37:  [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).
	strncat(f_setup.aux_name, EXT_AUX, strlen(EXT_AUX) + 1);
data/frotz-2.52+dfsg/src/curses/ux_init.c:781: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).
	size_t buf_sz = strlen(path) + strlen(name) + sizeof(DIRSEP) + 1;
data/frotz-2.52+dfsg/src/curses/ux_init.c:781:33:  [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).
	size_t buf_sz = strlen(path) + strlen(name) + sizeof(DIRSEP) + 1;
data/frotz-2.52+dfsg/src/curses/ux_init.c:794: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).
		memcpy(bp, name, strlen(name));
data/frotz-2.52+dfsg/src/curses/ux_init.c:798: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).
		bp[strlen(name)] = 0;
data/frotz-2.52+dfsg/src/curses/ux_init.c:847:15:  [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 (varname[strlen(varname)-1] != '\n')
data/frotz-2.52+dfsg/src/curses/ux_init.c:848:11:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
			while (fgetc(fp) != '\n')
data/frotz-2.52+dfsg/src/curses/ux_init.c:852: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).
		for (num = strlen(varname) - 1; (ssize_t) num >= 0 && isspace((int) varname[num]); num--)
data/frotz-2.52+dfsg/src/curses/ux_init.c:857:24:  [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).
		for (num = 0; num <= strlen(varname)+1; num++) {
data/frotz-2.52+dfsg/src/curses/ux_init.c:868:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(value, &varname[num2], LINELEN);
data/frotz-2.52+dfsg/src/curses/ux_init.c:956: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).
			size_t sz = strlen(value) * sizeof(char) + 1;
data/frotz-2.52+dfsg/src/curses/ux_init.c:1133:33:  [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 (c == 0) return (char *)s + strlen(s);
data/frotz-2.52+dfsg/src/curses/ux_input.c:1059:7:  [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(tempname) > 1)
data/frotz-2.52+dfsg/src/curses/ux_input.c:1065:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy (file_name, default_name, FILENAME_MAX);
data/frotz-2.52+dfsg/src/curses/ux_input.c:1074:12:  [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).
		for (i = strlen(file_name); i > 0; i--) {
data/frotz-2.52+dfsg/src/curses/ux_input.c:1081:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(file_name, f_setup.restricted_path, FILENAME_MAX);
data/frotz-2.52+dfsg/src/curses/ux_input.c:1084: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).
		if (file_name[strlen(file_name)-1] != PATH_SEPARATOR) {
data/frotz-2.52+dfsg/src/curses/ux_input.c:1085:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
			strncat(file_name, path_separator, FILENAME_MAX - strlen(file_name) - 2);
data/frotz-2.52+dfsg/src/curses/ux_input.c:1085:54:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			strncat(file_name, path_separator, FILENAME_MAX - strlen(file_name) - 2);
data/frotz-2.52+dfsg/src/curses/ux_input.c:1087:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat(file_name, tempname, strlen(file_name) - strlen(tempname) - 1);
data/frotz-2.52+dfsg/src/curses/ux_input.c:1087:32:  [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).
		strncat(file_name, tempname, strlen(file_name) - strlen(tempname) - 1);
data/frotz-2.52+dfsg/src/curses/ux_input.c:1087:52:  [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).
		strncat(file_name, tempname, strlen(file_name) - strlen(tempname) - 1);
data/frotz-2.52+dfsg/src/dos/bcinit.c:382:15:  [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 length = strlen(story_name) + strlen(extension) + 2;
data/frotz-2.52+dfsg/src/dos/bcinit.c:382:36:  [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 length = strlen(story_name) + strlen(extension) + 2;
data/frotz-2.52+dfsg/src/dos/bcinit.c:386:3:  [1] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant character.
		strcat(filename, ".");
data/frotz-2.52+dfsg/src/dos/bcinput.c:730: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).
	input.pos = strlen((char *) buf);
data/frotz-2.52+dfsg/src/dos/bcinput.c:731: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).
	input.length = strlen((char *) buf);
data/frotz-2.52+dfsg/src/dos/bcinput.c:892:12:  [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).
		for (i = strlen(file_name); i > 0; i--) {
data/frotz-2.52+dfsg/src/dos/bcinput.c:900: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).
		if (file_name[strlen(file_name)-1] != PATH_SEPARATOR) {
data/frotz-2.52+dfsg/src/dos/bcinput.c:901:4:  [1] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant character.
			strcat(file_name, "\\");
data/frotz-2.52+dfsg/src/dos/bcpic.c:269:11:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	if ((n = fgetc(file)) == 16)
data/frotz-2.52+dfsg/src/dos/bcpic.c:415:10:  [1] (buffer) fgetc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		bits = fgetc(file);
data/frotz-2.52+dfsg/src/dos/bcsample.c:278:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat(sample_name, f_setup.story_name, 6);
data/frotz-2.52+dfsg/src/dos/bcsample.c:279:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat(sample_name, numstr, 2);
data/frotz-2.52+dfsg/src/dos/bcsample.c:280:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings. Risk is low because the source is a
  constant string.
		strncat(sample_name, ".snd", 4);
data/frotz-2.52+dfsg/src/dumb/dblorb.c:80: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).
		len1 = strlen(filename) + strlen(EXT_BLORB);
data/frotz-2.52+dfsg/src/dumb/dblorb.c:80:29:  [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).
		len1 = strlen(filename) + strlen(EXT_BLORB);
data/frotz-2.52+dfsg/src/dumb/dblorb.c:81: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).
		len2 = strlen(filename) + strlen(EXT_BLORB3);
data/frotz-2.52+dfsg/src/dumb/dblorb.c:81:29:  [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).
		len2 = strlen(filename) + strlen(EXT_BLORB3);
data/frotz-2.52+dfsg/src/dumb/dblorb.c:89:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
			strncat(mystring, EXT_BLORB, len1);
data/frotz-2.52+dfsg/src/dumb/dblorb.c:96:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
			strncat(mystring, EXT_BLORB3, len2);
data/frotz-2.52+dfsg/src/dumb/dinit.c:224:32:  [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).
	f_setup.script_name = malloc((strlen(f_setup.story_name) +
data/frotz-2.52+dfsg/src/dumb/dinit.c:225:3:  [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(EXT_SCRIPT)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:226:55:  [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).
    	memcpy(f_setup.script_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SCRIPT)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:226:84:  [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).
    	memcpy(f_setup.script_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SCRIPT)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:228:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(f_setup.script_name, EXT_SCRIPT, strlen(EXT_SCRIPT) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:228:43:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	strncat(f_setup.script_name, EXT_SCRIPT, strlen(EXT_SCRIPT) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:230:33:  [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).
	f_setup.command_name = malloc((strlen(f_setup.story_name) +
data/frotz-2.52+dfsg/src/dumb/dinit.c:231:3:  [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(EXT_COMMAND)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:232:52:  [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).
	memcpy(f_setup.command_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_COMMAND)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:232:81:  [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).
	memcpy(f_setup.command_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_COMMAND)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:233:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(f_setup.command_name, EXT_COMMAND, strlen(EXT_COMMAND) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:233:45:  [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).
	strncat(f_setup.command_name, EXT_COMMAND, strlen(EXT_COMMAND) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:236:31:  [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).
		f_setup.save_name = malloc((strlen(f_setup.story_name) +
data/frotz-2.52+dfsg/src/dumb/dinit.c:237:4:  [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(EXT_SAVE)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:238: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).
		memcpy(f_setup.save_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:238:79:  [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).
		memcpy(f_setup.save_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:239:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat(f_setup.save_name, EXT_SAVE, strlen(EXT_SAVE) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:239: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).
		strncat(f_setup.save_name, EXT_SAVE, strlen(EXT_SAVE) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:241:31:  [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).
		f_setup.save_name = malloc((strlen(f_setup.tmp_save_name) +
data/frotz-2.52+dfsg/src/dumb/dinit.c:242:4:  [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(EXT_SAVE)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:243:53:  [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).
		memcpy(f_setup.save_name, f_setup.tmp_save_name, (strlen(f_setup.tmp_save_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:243:85:  [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).
		memcpy(f_setup.save_name, f_setup.tmp_save_name, (strlen(f_setup.tmp_save_name) + strlen(EXT_SAVE)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:247:29:  [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).
	f_setup.aux_name = malloc((strlen(f_setup.story_name) +
data/frotz-2.52+dfsg/src/dumb/dinit.c:248:3:  [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(EXT_AUX)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:249: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).
	memcpy(f_setup.aux_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_AUX)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:249:77:  [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).
	memcpy(f_setup.aux_name, f_setup.story_name, (strlen(f_setup.story_name) + strlen(EXT_AUX)) * sizeof(char));
data/frotz-2.52+dfsg/src/dumb/dinit.c:250:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(f_setup.aux_name, EXT_AUX, strlen(EXT_AUX) + 1);
data/frotz-2.52+dfsg/src/dumb/dinit.c:250:37:  [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).
	strncat(f_setup.aux_name, EXT_AUX, strlen(EXT_AUX) + 1);
data/frotz-2.52+dfsg/src/dumb/dinput.c:87:10:  [1] (buffer) getchar:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	int c = getchar();
data/frotz-2.52+dfsg/src/dumb/dinput.c:259: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).
		command[strlen(command) - 1] = '\0';
data/frotz-2.52+dfsg/src/dumb/dinput.c:285:28:  [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).
				dumb_discard_old_input(strlen((char*) continued_line_chars));
data/frotz-2.52+dfsg/src/dumb/dinput.c:327:4:  [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).
	s[strlen(s) - 1] = '\0';
data/frotz-2.52+dfsg/src/dumb/dinput.c:389:7:  [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(read_key_buffer) > 1)
data/frotz-2.52+dfsg/src/dumb/dinput.c:390: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).
			read_key_buffer[strlen(read_key_buffer) - 1] = '\0';
data/frotz-2.52+dfsg/src/dumb/dinput.c:403:3:  [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(read_key_buffer) - idx + 1);
data/frotz-2.52+dfsg/src/dumb/dinput.c:457:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat((char*) buf, (char *) read_line_buffer,
data/frotz-2.52+dfsg/src/dumb/dinput.c:458:23:  [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).
		INPUT_BUFFER_SIZE - strlen(read_line_buffer) - 1);
data/frotz-2.52+dfsg/src/dumb/dinput.c:472:25:  [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).
	p = read_line_buffer + strlen(read_line_buffer) + 1;
data/frotz-2.52+dfsg/src/dumb/dinput.c:473:31:  [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).
	memmove(read_line_buffer, p, strlen(p) + 1);
data/frotz-2.52+dfsg/src/dumb/dinput.c:505:13:  [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).
			for (i = strlen(default_name); i > 0; i--) {
data/frotz-2.52+dfsg/src/dumb/dinput.c:520:7:  [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(buf) > MAX_FILE_NAME) {
data/frotz-2.52+dfsg/src/dumb/dinput.c:527:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(file_name, fullpath, FILENAME_MAX);
data/frotz-2.52+dfsg/src/dumb/dinput.c:529:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(file_name, default_name, FILENAME_MAX);
data/frotz-2.52+dfsg/src/dumb/dinput.c:533:12:  [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).
		for (i = strlen(file_name); i > 0; i--) {
data/frotz-2.52+dfsg/src/dumb/dinput.c:540:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(file_name, f_setup.restricted_path, FILENAME_MAX);
data/frotz-2.52+dfsg/src/dumb/dinput.c:543: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).
		if (file_name[strlen(file_name)-1] != PATH_SEPARATOR) {
data/frotz-2.52+dfsg/src/dumb/dinput.c:544:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
			strncat(file_name, path_separator, FILENAME_MAX - strlen(file_name) - 2);
data/frotz-2.52+dfsg/src/dumb/dinput.c:544:54:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
			strncat(file_name, path_separator, FILENAME_MAX - strlen(file_name) - 2);
data/frotz-2.52+dfsg/src/dumb/dinput.c:546:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat(file_name, tempname, strlen(file_name) - strlen(tempname) - 1);
data/frotz-2.52+dfsg/src/dumb/dinput.c:546:32:  [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).
		strncat(file_name, tempname, strlen(file_name) - strlen(tempname) - 1);
data/frotz-2.52+dfsg/src/dumb/dinput.c:546:52:  [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).
		strncat(file_name, tempname, strlen(file_name) - strlen(tempname) - 1);
data/frotz-2.52+dfsg/src/dumb/doutput.c:904:13:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		case 'b': strncpy(rv_blank_str, setting[2] ? &setting[2] : " ", 4); break;
data/frotz-2.52+dfsg/src/sdl/generic.c:104: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).
		len1 = strlen(filename) + strlen(EXT_BLORB);
data/frotz-2.52+dfsg/src/sdl/generic.c:104:29:  [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).
		len1 = strlen(filename) + strlen(EXT_BLORB);
data/frotz-2.52+dfsg/src/sdl/generic.c:105: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).
		len2 = strlen(filename) + strlen(EXT_BLORB3);
data/frotz-2.52+dfsg/src/sdl/generic.c:105:29:  [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).
		len2 = strlen(filename) + strlen(EXT_BLORB3);
data/frotz-2.52+dfsg/src/sdl/generic.c:114:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
			strncat(mystring, EXT_BLORB, len1);
data/frotz-2.52+dfsg/src/sdl/generic.c:122:4:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
			strncat(mystring, EXT_BLORB3, len2 * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:46:12:  [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 len = strlen(id);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:191: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(fontname) + strlen(copyright) + 2;
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:191:25:  [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(fontname) + strlen(copyright) + 2;
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:202: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).
	k = strlen(fontname) + 1;
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:207: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).
	k = strlen(copyright) + 1;
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:978: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).
		fnlen = strlen(fn);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:987: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).
			plen = strlen(paths);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:989:4:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
			strncpy(buf, paths, plen);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:992:4:  [1] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant character.
			strcat(buf, "/");
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:993: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).
		plen = strlen(buf);
data/frotz-2.52+dfsg/src/sdl/sf_fonts.c:994:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(buf + plen, fn, fnlen);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:81: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(lastdir) < 2)
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:83: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).
	lastdir[strlen(lastdir) - 1] = 0;
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:89:3:  [1] (buffer) strcat:
  Does not check for buffer overflows when concatenating to destination
  [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or
  snprintf (warning: strncat is easily misused). Risk is low because the
  source is a constant character.
		strcat(lastdir, "/");
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:238: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 wt = wtext * strlen(s);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:570: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).
	lpat = strlen(pattern);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:575:7:  [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).
	lp = strlen(p);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:653: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).
		int n = strlen(p);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:689: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).
	resdend = resdir + strlen(resdir);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:692: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).
	n = strlen(resdir);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:857: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(s) > n) {
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:1012:13:  [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).
	heff = 8 * strlen(t);
data/frotz-2.52+dfsg/src/sdl/sf_osfdlg.c:1094: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).
	n = strlen(filename);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:161:15:  [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).
	buf = malloc(strlen(path) + strlen(name) + 2);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:161:30:  [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).
	buf = malloc(strlen(path) + strlen(name) + 2);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:169: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).
		memcpy(bp, name, strlen(name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:170: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).
		bp[strlen(name)] = 0;
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:459: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).
		fontdir_len = strlen(m_fontdir);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:460: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).
		homedir_len = strlen(myhome);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:858: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).
	sprintf(buf + strlen(buf), tpl, num);
data/frotz-2.52+dfsg/src/sdl/sf_resource.c:1012: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).
	n = strlen(p);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:223: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).
				len = WIDCOL - strlen(*p) - 2;
data/frotz-2.52+dfsg/src/sdl/sf_util.c:443:7:  [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(p) >= 2 && strlen(p) <= 7) {
data/frotz-2.52+dfsg/src/sdl/sf_util.c:443:25:  [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(p) >= 2 && strlen(p) <= 7) {
data/frotz-2.52+dfsg/src/sdl/sf_util.c:451: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).
	    malloc((strlen(f_setup.story_name) +
data/frotz-2.52+dfsg/src/sdl/sf_util.c:452:7:  [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(EXT_SCRIPT)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:453: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).
	memcpy(f_setup.script_name, f_setup.story_name, strlen(f_setup.story_name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:454:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(f_setup.script_name, EXT_SCRIPT, strlen(EXT_SCRIPT) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:454:43:  [1] (buffer) strlen:
  Does not handle strings that are not \0-terminated; if given one it may
  perform an over-read (it could cause a crash if unprotected) (CWE-126).
	strncat(f_setup.script_name, EXT_SCRIPT, strlen(EXT_SCRIPT) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:457: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).
	    malloc((strlen(f_setup.story_name) +
data/frotz-2.52+dfsg/src/sdl/sf_util.c:458:7:  [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(EXT_COMMAND)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:459:51:  [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).
	memcpy(f_setup.command_name, f_setup.story_name, strlen(f_setup.story_name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:460:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(f_setup.command_name, EXT_COMMAND, strlen(EXT_COMMAND) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:460:45:  [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).
	strncat(f_setup.command_name, EXT_COMMAND, strlen(EXT_COMMAND) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:464:15:  [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).
		    malloc((strlen(f_setup.story_name) +
data/frotz-2.52+dfsg/src/sdl/sf_util.c:465: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).
			    strlen(EXT_SAVE)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:466: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).
		memcpy(f_setup.save_name, f_setup.story_name, strlen(f_setup.story_name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:467:3:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
		strncat(f_setup.save_name, EXT_SAVE, strlen(EXT_SAVE) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:467: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).
		strncat(f_setup.save_name, EXT_SAVE, strlen(EXT_SAVE) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:470:15:  [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).
		    malloc((strlen(f_setup.tmp_save_name) +
data/frotz-2.52+dfsg/src/sdl/sf_util.c:471: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).
			    strlen(EXT_SAVE)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:472:52:  [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).
		memcpy(f_setup.save_name, f_setup.tmp_save_name, strlen(f_setup.tmp_save_name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:477: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).
	    malloc((strlen(f_setup.story_name) +
data/frotz-2.52+dfsg/src/sdl/sf_util.c:478:7:  [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(EXT_AUX)) * sizeof(char) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:479: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).
	memcpy(f_setup.aux_name, f_setup.story_name, strlen(f_setup.story_name) * sizeof(char));
data/frotz-2.52+dfsg/src/sdl/sf_util.c:480:2:  [1] (buffer) strncat:
  Easily used incorrectly (e.g., incorrectly computing the correct maximum
  size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf,
  or automatically resizing strings.
	strncat(f_setup.aux_name, EXT_AUX, strlen(EXT_AUX) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:480:37:  [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).
	strncat(f_setup.aux_name, EXT_AUX, strlen(EXT_AUX) + 1);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:571: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).
	len = strlen(buf);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:591: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).
	len = strlen(buf);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:643:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(file_name, f_setup.save_name, FILENAME_MAX);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:799:3:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
		strncpy(file_name, res, MAX_FILE_NAME);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:830: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(homedir) + strlen(fn) + 1) * sizeof(char)) + 1;
data/frotz-2.52+dfsg/src/sdl/sf_util.c:830:28:  [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(homedir) + strlen(fn) + 1) * sizeof(char)) + 1;
data/frotz-2.52+dfsg/src/sdl/sf_util.c:875: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).
	int ns = strlen(sect);
data/frotz-2.52+dfsg/src/sdl/sf_util.c:892:12:  [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 nid = strlen(id);

ANALYSIS SUMMARY:

Hits = 449
Lines analyzed = 35998 in approximately 1.02 seconds (35149 lines/second)
Physical Source Lines of Code (SLOC) = 24170
Hits@level = [0] 159 [1] 224 [2] 171 [3]  12 [4]  42 [5]   0
Hits@level+ = [0+] 608 [1+] 449 [2+] 225 [3+]  54 [4+]  42 [5+]   0
Hits/KSLOC@level+ = [0+] 25.1552 [1+] 18.5767 [2+] 9.30906 [3+] 2.23417 [4+] 1.73769 [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.