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/vcftools-0.1.16/src/cpp/bcf_entry.cpp
Examining data/vcftools-0.1.16/src/cpp/bcf_entry.h
Examining data/vcftools-0.1.16/src/cpp/bcf_entry_setters.cpp
Examining data/vcftools-0.1.16/src/cpp/bcf_file.cpp
Examining data/vcftools-0.1.16/src/cpp/bcf_file.h
Examining data/vcftools-0.1.16/src/cpp/bgzf.c
Examining data/vcftools-0.1.16/src/cpp/bgzf.h
Examining data/vcftools-0.1.16/src/cpp/dgeev.cpp
Examining data/vcftools-0.1.16/src/cpp/dgeev.h
Examining data/vcftools-0.1.16/src/cpp/entry.cpp
Examining data/vcftools-0.1.16/src/cpp/entry.h
Examining data/vcftools-0.1.16/src/cpp/entry_filters.cpp
Examining data/vcftools-0.1.16/src/cpp/entry_getters.cpp
Examining data/vcftools-0.1.16/src/cpp/entry_setters.cpp
Examining data/vcftools-0.1.16/src/cpp/gamma.cpp
Examining data/vcftools-0.1.16/src/cpp/gamma.h
Examining data/vcftools-0.1.16/src/cpp/header.cpp
Examining data/vcftools-0.1.16/src/cpp/header.h
Examining data/vcftools-0.1.16/src/cpp/khash.h
Examining data/vcftools-0.1.16/src/cpp/knetfile.c
Examining data/vcftools-0.1.16/src/cpp/knetfile.h
Examining data/vcftools-0.1.16/src/cpp/output_log.cpp
Examining data/vcftools-0.1.16/src/cpp/output_log.h
Examining data/vcftools-0.1.16/src/cpp/parameters.cpp
Examining data/vcftools-0.1.16/src/cpp/parameters.h
Examining data/vcftools-0.1.16/src/cpp/variant_file.cpp
Examining data/vcftools-0.1.16/src/cpp/variant_file.h
Examining data/vcftools-0.1.16/src/cpp/variant_file_diff.cpp
Examining data/vcftools-0.1.16/src/cpp/variant_file_filters.cpp
Examining data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp
Examining data/vcftools-0.1.16/src/cpp/vcf_entry.cpp
Examining data/vcftools-0.1.16/src/cpp/vcf_entry.h
Examining data/vcftools-0.1.16/src/cpp/vcf_entry_setters.cpp
Examining data/vcftools-0.1.16/src/cpp/vcf_file.cpp
Examining data/vcftools-0.1.16/src/cpp/vcf_file.h
Examining data/vcftools-0.1.16/src/cpp/vcftools.cpp
Examining data/vcftools-0.1.16/src/cpp/vcftools.h
Examining data/vcftools-0.1.16/src/cpp/variant_file_output.cpp

FINAL RESULTS:

data/vcftools-0.1.16/src/cpp/knetfile.c:311:2:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	sprintf(fp->retr, "RETR %s\r\n", p);
data/vcftools-0.1.16/src/cpp/knetfile.c:313:5:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
    sprintf(fp->size_cmd, "SIZE %s\r\n", p);
data/vcftools-0.1.16/src/cpp/knetfile.c:412:7:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
	l += sprintf(buf + l, "GET %s HTTP/1.0\r\nHost: %s\r\n", fp->path, fp->http_host);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:30: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:404: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:629: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:659: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:681: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(tmpname2, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:812: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:842: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:996: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:1027: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:1049: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(tmpname2, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1443: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1620: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1794: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1959: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2116: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2321: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2330: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(tmpname2, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2562: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(tmpname, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2571: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(tmpname2, new_tmp.c_str());
data/vcftools-0.1.16/src/cpp/knetfile.c:386: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.
	proxy = getenv("http_proxy");
data/vcftools-0.1.16/src/cpp/parameters.cpp:148:20:  [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.
	const char* raw = getenv("TMPDIR");	// Get environment variable
data/vcftools-0.1.16/src/cpp/variant_file_filters.cpp:117:2:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
	srand ( time(NULL) );
data/vcftools-0.1.16/src/cpp/bcf_entry.cpp:312:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(&tmp[0], &line[l_pos], size*sizeof(char));
data/vcftools-0.1.16/src/cpp/bcf_entry.cpp:623:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[0], &line[0], INFO_pos);
data/vcftools-0.1.16/src/cpp/bcf_entry.cpp:629: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(&out_vector[curr_size], &line[INFO_pos], (FORMAT_pos - INFO_pos));
data/vcftools-0.1.16/src/cpp/bcf_entry.cpp:638: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(&out_vector[6*sizeof(int32_t)], &tmp_vector[0], sizeof(char));
data/vcftools-0.1.16/src/cpp/bcf_entry.cpp:667:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[0], &l_shared, sizeof(uint32_t));
data/vcftools-0.1.16/src/cpp/bcf_entry.cpp:695:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(&tmp_vector[0], &line[l_pos], FORMAT_skip[ui]);
data/vcftools-0.1.16/src/cpp/bcf_entry.cpp:701:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[sizeof(uint32_t)], &l_indv, sizeof(uint32_t));
data/vcftools-0.1.16/src/cpp/bcf_entry_setters.cpp:191: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 phased[2] = {'/', '|'};
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:10: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 bcf_21[5] = {'B','C','F',(int8_t)2,(int8_t)1};
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:11: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 bcf_22[5] = {'B','C','F',(int8_t)2,(int8_t)2};
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:31:3:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		open();
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:44:16:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
void bcf_file::open()
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:65:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		file_tmp.open(filename.c_str(), ios::in);
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:99: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 magic[5];
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:123: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(&out[0], size_int, 2*sizeof(uint32_t));
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:205:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:263: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 magic[5] = {'B','C','F','\2','\2'};
data/vcftools-0.1.16/src/cpp/bcf_file.h:41:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	void open();
data/vcftools-0.1.16/src/cpp/bgzf.c:54:30:  [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).
#define _bgzf_open(fn, mode) fopen((fn), (mode))
data/vcftools-0.1.16/src/cpp/bgzf.c:155: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 ((fpw = fopen(path, "w")) == 0) return 0;
data/vcftools-0.1.16/src/cpp/bgzf.c:199: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(dst, g_magic, BLOCK_HEADER_LENGTH); // the last two bytes are a place holder for the length of the block
data/vcftools-0.1.16/src/cpp/bgzf.c:277: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(fp->uncompressed_block, p->block, BGZF_MAX_BLOCK_SIZE);
data/vcftools-0.1.16/src/cpp/bgzf.c:306: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(kh_val(h, k).block, fp->uncompressed_block, BGZF_MAX_BLOCK_SIZE);
data/vcftools-0.1.16/src/cpp/bgzf.c:333: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(compressed_block, header, BLOCK_HEADER_LENGTH);
data/vcftools-0.1.16/src/cpp/bgzf.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(output, buffer + fp->block_offset, copy_length);
data/vcftools-0.1.16/src/cpp/bgzf.c:413: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(w->mt->blk[i], w->buf, clen);
data/vcftools-0.1.16/src/cpp/bgzf.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(mt->blk[mt->curr], fp->uncompressed_block, fp->block_offset);
data/vcftools-0.1.16/src/cpp/bgzf.c:524: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((uint8_t*)fp->uncompressed_block + fp->block_offset, input, copy_length);
data/vcftools-0.1.16/src/cpp/bgzf.c:576: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(buffer + fp->block_offset, input, copy_length);
data/vcftools-0.1.16/src/cpp/bgzf.c:698: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(str->s + str->l, buf + fp->block_offset, l);
data/vcftools-0.1.16/src/cpp/entry.cpp:593: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 missing[4] = {static_cast<char>(0x01), static_cast<char>(0x00), static_cast<char>(0x80), static_cast<char>(0x7F)};
data/vcftools-0.1.16/src/cpp/entry.cpp:594: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 end[4] = {static_cast<char>(0x02), static_cast<char>(0x00), static_cast<char>(0x80), static_cast<char>(0x7F)};
data/vcftools-0.1.16/src/cpp/entry.cpp:656: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 missing[4] = {static_cast<char>(0x01), static_cast<char>(0x00), static_cast<char>(0x80), static_cast<char>(0x7F)};
data/vcftools-0.1.16/src/cpp/entry.cpp:657: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 end[4] = {static_cast<char>(0x02), static_cast<char>(0x00), static_cast<char>(0x80), static_cast<char>(0x7F)};
data/vcftools-0.1.16/src/cpp/entry.cpp:718: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(tmp, &line[*line_position], size*sizeof(char));
data/vcftools-0.1.16/src/cpp/entry.cpp:877: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 missing_float[4] = {static_cast<char>(0x01), static_cast<char>(0x00), static_cast<char>(0x80), static_cast<char>(0x7F)};
data/vcftools-0.1.16/src/cpp/entry.cpp:879: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 missing_int2[2] = {static_cast<char>(0x00), static_cast<char>(0x80)};
data/vcftools-0.1.16/src/cpp/entry.cpp:880: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 missing_int3[4] = {static_cast<char>(0x00), static_cast<char>(0x00), static_cast<char>(0x00), static_cast<char>(0x80)};
data/vcftools-0.1.16/src/cpp/entry.cpp:936: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 end_float[4] = {static_cast<char>(0x02), static_cast<char>(0x00), static_cast<char>(0x80), static_cast<char>(0x7F)};
data/vcftools-0.1.16/src/cpp/entry.cpp:938: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 end_int2[2] = {static_cast<char>(0x01), static_cast<char>(0x80)};
data/vcftools-0.1.16/src/cpp/entry.cpp:939: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 end_int3[4] = {static_cast<char>(0x01), static_cast<char>(0x00), static_cast<char>(0x00), static_cast<char>(0x80)};
data/vcftools-0.1.16/src/cpp/entry_filters.cpp:682:8:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		mask.open(mask_file.c_str());
data/vcftools-0.1.16/src/cpp/entry_getters.cpp:486:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out[0], &pos, sizeof(pos));
data/vcftools-0.1.16/src/cpp/entry_getters.cpp:497:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out[0], &rlen, sizeof(rlen));
data/vcftools-0.1.16/src/cpp/entry_getters.cpp:504:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out[0], &qual, sizeof(qual));
data/vcftools-0.1.16/src/cpp/entry_getters.cpp:516:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out[0], &n_allele_info, sizeof(n_allele_info));
data/vcftools-0.1.16/src/cpp/entry_getters.cpp:528:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out[0], &n_fmt_sample, sizeof(n_fmt_sample));
data/vcftools-0.1.16/src/cpp/header.cpp:510: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).
		return atoi(in.c_str());
data/vcftools-0.1.16/src/cpp/knetfile.c:175: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).
	server.sin_port = htons(atoi(port));
data/vcftools-0.1.16/src/cpp/knetfile.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(ftp->pasv_ip, v, 4 * sizeof(int));
data/vcftools-0.1.16/src/cpp/knetfile.c:257: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 host[80], port[10];
data/vcftools-0.1.16/src/cpp/knetfile.c:262: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(host, "%d.%d.%d.%d", ftp->pasv_ip[0], ftp->pasv_ip[1], ftp->pasv_ip[2], ftp->pasv_ip[3]);
data/vcftools-0.1.16/src/cpp/knetfile.c:263: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(port, "%d", ftp->pasv_port);
data/vcftools-0.1.16/src/cpp/knetfile.c:342:3:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
		char tmp[32];
data/vcftools-0.1.16/src/cpp/knetfile.c:344:3:  [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(tmp, "REST %lld\r\n", (long long)fp->offset);
data/vcftools-0.1.16/src/cpp/knetfile.c:346: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(tmp, "REST ");
data/vcftools-0.1.16/src/cpp/knetfile.c:348:3:  [2] (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 string.
		strcat(tmp, "\r\n");
data/vcftools-0.1.16/src/cpp/knetfile.c:413:10:  [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.
    l += sprintf(buf + l, "Range: bytes=%lld-\r\n", (long long)fp->offset);
data/vcftools-0.1.16/src/cpp/knetfile.c:414:7:  [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.
	l += sprintf(buf + l, "\r\n");
data/vcftools-0.1.16/src/cpp/knetfile.c:475:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		int fd = open(fn, O_RDONLY | O_BINARY);
data/vcftools-0.1.16/src/cpp/knetfile.c:477:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		int fd = open(fn, O_RDONLY);
data/vcftools-0.1.16/src/cpp/output_log.cpp:17:18:  [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).
void output_log::open(bool stout, bool sterr, const string &filename_prefix)
data/vcftools-0.1.16/src/cpp/output_log.cpp:32:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		LOG.open((filename_prefix + ".log").c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/output_log.h:29:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	void open(bool stout, bool sterr, const string &filename);
data/vcftools-0.1.16/src/cpp/parameters.cpp:226:49:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--from-bp") { start_pos = atoi(get_arg(i+1).c_str()); i++; }					// Start position
data/vcftools-0.1.16/src/cpp/parameters.cpp:227:63:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--fst-window-size") { fst_window_size = atoi(get_arg(i+1).c_str()); i++; }                  // Window size for Fst calculation
data/vcftools-0.1.16/src/cpp/parameters.cpp:228:63:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--fst-window-step") { fst_window_step = atoi(get_arg(i+1).c_str()); i++; }                  // Window step for Fst calculation
data/vcftools-0.1.16/src/cpp/parameters.cpp:269:62:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--ld-window-bp") { ld_bp_window_size = atoi(get_arg(i+1).c_str()); i++; }	// Max bp distance for LD output
data/vcftools-0.1.16/src/cpp/parameters.cpp:270:60:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--ld-window") { ld_snp_window_size = atoi(get_arg(i+1).c_str()); i++; }		// Max SNP distance for LD output
data/vcftools-0.1.16/src/cpp/parameters.cpp:271:65:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--ld-window-bp-min") { ld_bp_window_min = atoi(get_arg(i+1).c_str()); i++; }	// Max bp distance for LD output
data/vcftools-0.1.16/src/cpp/parameters.cpp:272:63:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--ld-window-min") { ld_snp_window_min = atoi(get_arg(i+1).c_str()); i++; }		// Max SNP distance for LD output
data/vcftools-0.1.16/src/cpp/parameters.cpp:277:43:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--mac") { min_mac = atoi(get_arg(i+1).c_str()); i++; }								// Minimum Site MAC
data/vcftools-0.1.16/src/cpp/parameters.cpp:279:60:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--mask-min") { min_kept_mask_value = atoi(get_arg(i+1).c_str()); i++; }
data/vcftools-0.1.16/src/cpp/parameters.cpp:281:55:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--max-alleles") { max_alleles = atoi(get_arg(i+1).c_str()); i++; }				// Maximum number of alleles per-site
data/vcftools-0.1.16/src/cpp/parameters.cpp:282:47:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--max-mac") { max_mac = atoi(get_arg(i+1).c_str()); i++; }						// Maximum site MAC
data/vcftools-0.1.16/src/cpp/parameters.cpp:286:72:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--max-missing-count") { max_missing_call_count = atoi(get_arg(i+1).c_str()); i++; } // Site maximum missing genotypes
data/vcftools-0.1.16/src/cpp/parameters.cpp:287:61:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--max-non-ref-ac") { max_non_ref_ac = atoi(get_arg(i+1).c_str()); i++; }		// Minimum Site non-ref AC
data/vcftools-0.1.16/src/cpp/parameters.cpp:289:69:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--max-non-ref-ac-any") { max_non_ref_ac_any = atoi(get_arg(i+1).c_str()); i++; }		// Minimum Site non-ref AC
data/vcftools-0.1.16/src/cpp/parameters.cpp:291:56:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--maxDP") { max_genotype_depth = atoi(get_arg(i+1).c_str()); i++; }				// Maximum genotype depth
data/vcftools-0.1.16/src/cpp/parameters.cpp:292:50:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--max-indv") {max_N_indv = atoi(get_arg(i+1).c_str()); i++; }
data/vcftools-0.1.16/src/cpp/parameters.cpp:294:55:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--min-alleles") { min_alleles = atoi(get_arg(i+1).c_str()); i++; }				// Minimum number of alleles per-site
data/vcftools-0.1.16/src/cpp/parameters.cpp:297:56:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--minDP") { min_genotype_depth = atoi(get_arg(i+1).c_str()); i++; }				// Minimum genotype depth
data/vcftools-0.1.16/src/cpp/parameters.cpp:302:57:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--non-ref-ac") { min_non_ref_ac = atoi(get_arg(i+1).c_str()); i++; }				// Minimum Site non-ref AC
data/vcftools-0.1.16/src/cpp/parameters.cpp:304:65:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--non-ref-ac-any") { min_non_ref_ac_any = atoi(get_arg(i+1).c_str()); i++; }				// Minimum Site non-ref AC
data/vcftools-0.1.16/src/cpp/parameters.cpp:310:74:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--pca-snp-loadings") { output_N_PCA_SNP_loadings = atoi(get_arg(i+1).c_str()); min_alleles=2; max_alleles=2; i++; num_outputs++;}
data/vcftools-0.1.16/src/cpp/parameters.cpp:337:70:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--SNPdensity") { output_SNP_density_bin_size = atoi(get_arg(i+1).c_str()); num_outputs++; i++; }	// Output SNP density using Bin Size
data/vcftools-0.1.16/src/cpp/parameters.cpp:340:64:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--TajimaD") { output_Tajima_D_bin_size = atoi(get_arg(i+1).c_str()); i++; num_outputs++;} //Output Tajima D
data/vcftools-0.1.16/src/cpp/parameters.cpp:342:45:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--to-bp") { end_pos = atoi(get_arg(i+1).c_str()); i++; }						// End position
data/vcftools-0.1.16/src/cpp/parameters.cpp:343:58:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--thin") { min_interSNP_distance = atoi(get_arg(i+1).c_str()); i++; }	// Set minimum distance between SNPs
data/vcftools-0.1.16/src/cpp/parameters.cpp:344:56:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--TsTv") {output_TsTv_bin_size = atoi(get_arg(i+1).c_str()); i++; num_outputs++;}				// Output Ts/Tv stats
data/vcftools-0.1.16/src/cpp/parameters.cpp:349:56:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--window-pi") { pi_window_size = atoi(get_arg(i+1).c_str()); i++; num_outputs++;}
data/vcftools-0.1.16/src/cpp/parameters.cpp:350:61:  [2] (integer) atoi:
  Unless checked, the resulting number can exceed the expected range
  (CWE-190). If source untrusted, check both minimum and maximum, even if the
  input had no minus sign (large numbers can roll over into negative number;
  consider saving to an unsigned value if that is intended).
		else if (in_str == "--window-pi-step") { pi_window_step = atoi(get_arg(i+1).c_str()); i++; }
data/vcftools-0.1.16/src/cpp/variant_file.h:72:15:  [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).
	virtual void open() = 0;
data/vcftools-0.1.16/src/cpp/variant_file_diff.cpp:86:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_diff.cpp:294:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_diff.cpp:607:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_diff.cpp:669:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_diff.cpp:1185:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_diff.cpp:1239:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:29: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:32:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
		fd = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:403: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:406:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
		fd = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:631:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:658: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:660:9:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
		ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:680: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 tmpname2[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:682:9:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
		ret = mkstemp(tmpname2);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:811:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:814:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:841: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:844:9:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
		ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:995: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:998:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:1026: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:1028:9:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
		ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:1048: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 tmpname2[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:1050:9:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
		ret = mkstemp(tmpname2);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:1168:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:1216:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_format_convert.cpp:1286:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:25:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:178:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:294:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:389:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:512:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:641:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:708:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:789:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:861:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1231:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1421:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1442: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1445:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1597:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1619: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1622:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1770:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1793: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1796:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1937:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1958: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:1961:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2093:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2115: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2118:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2303:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2320: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2323:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2329: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 tmpname2[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2332:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname2);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2545:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2561: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 tmpname[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2564:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2570: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 tmpname2[new_tmp.size()];
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2573:8:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
	ret = mkstemp(tmpname2);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2728:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2814:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:2940:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:3049:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:3121:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:3210:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:3292:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:3361:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:3402:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:3516:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:3840:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:3884:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:4032:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:4171:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:4230:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:4273:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:4337:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:4590:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:4707:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:4822:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:4999:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:5195:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/variant_file_output.cpp:5326:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:71: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).
		POS = atoi(ID.c_str());
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:397:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[vector_pos], &chrom, sizeof(chrom));
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:401:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[vector_pos], &tmp_vector[0], tmp_vector.size());
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:406:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[vector_pos], &tmp_vector[0], tmp_vector.size());
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:411:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[vector_pos], &tmp_vector[0], tmp_vector.size());
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:480:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[0], &l_shared, sizeof(l_shared));
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:484:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[vector_pos], &tmp_vector[0], tmp_vector.size());
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:501: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(&out_vector[out_size], &tmp_vector[old_pos], key_size );
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:525:5:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
				memcpy(&out_vector[out_size], &tmp_vector[format_pos], skip_size);
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:532:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[vector_pos], &tmp_vector[0], tmp_vector.size());
data/vcftools-0.1.16/src/cpp/vcf_entry.cpp:535:2:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
	memcpy(&out_vector[sizeof(l_shared)], &l_indv, sizeof(l_indv));
data/vcftools-0.1.16/src/cpp/vcf_file.cpp:40:3:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		open();
data/vcftools-0.1.16/src/cpp/vcf_file.cpp:82:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		temp_out.open(output_file.c_str(), ios::out);
data/vcftools-0.1.16/src/cpp/vcf_file.cpp:135:2:  [2] (buffer) char:
  Statically-sized arrays can be improperly restricted, leading to potential
  overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use
  functions that limit length, or ensure that the size is larger than the
  maximum possible length.
	char magic[5] = {'B','C','F','\2', '\2'};
data/vcftools-0.1.16/src/cpp/vcf_file.cpp:205:16:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
void vcf_file::open()
data/vcftools-0.1.16/src/cpp/vcf_file.cpp:225:12:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
		file_tmp.open(filename.c_str(), ios::in);
data/vcftools-0.1.16/src/cpp/vcf_file.h:36:7:  [2] (misc) open:
  Check when opening files - can an attacker redirect it (via symlinks),
  force the opening of special file type (e.g., device files), move things
  around to create a race condition, control its ancestors, or change its
  contents? (CWE-362).
	void open();
data/vcftools-0.1.16/src/cpp/vcftools.cpp:22:6:  [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).
	LOG.open(params.stream_out, params.stream_err, params.output_prefix);
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:101:2:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	read(magic, 5, 1);
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:117:8:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	ret = read(&size_int[0], 2, sizeof(uint32_t) );
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:124:3:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		read(&out[2*sizeof(uint32_t)], 1, read_size);
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:135:15:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
int bcf_file::read(void *buffer, unsigned int len, size_t size)
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:146:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		file_in->read((char*)buffer, size*len);
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:163:2:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	read(&len_text, 1, sizeof(uint32_t));
data/vcftools-0.1.16/src/cpp/bcf_file.cpp:165:2:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	read(header_array, len_text, 1);
data/vcftools-0.1.16/src/cpp/bcf_file.h:38:6:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	int read(void *buffer, unsigned int len, size_t size);
data/vcftools-0.1.16/src/cpp/entry_filters.cpp:312: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).
				if (strlen(gz_readbuffer) != gzMAX_LINE_LEN-1)
data/vcftools-0.1.16/src/cpp/entry_filters.cpp:359: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).
				if (strlen(gz_readbuffer) != gzMAX_LINE_LEN-1)
data/vcftools-0.1.16/src/cpp/entry_filters.cpp:440: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).
				if (strlen(gz_readbuffer) != gzMAX_LINE_LEN-1)
data/vcftools-0.1.16/src/cpp/entry_filters.cpp:486: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).
				if (strlen(gz_readbuffer) != gzMAX_LINE_LEN-1)
data/vcftools-0.1.16/src/cpp/knetfile.c:236: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).
	netwrite(ftp->ctrl_fd, cmd, strlen(cmd));
data/vcftools-0.1.16/src/cpp/knetfile.c:309:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(fp->host, fn + 6, l);
data/vcftools-0.1.16/src/cpp/knetfile.c:310:27:  [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).
	fp->retr = (char*)calloc(strlen(p) + 8, 1);
data/vcftools-0.1.16/src/cpp/knetfile.c:312:34:  [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).
    fp->size_cmd = (char*)calloc(strlen(p) + 8, 1);
data/vcftools-0.1.16/src/cpp/knetfile.c:381:2:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
	strncpy(fp->http_host, fn + 7, l);
data/vcftools-0.1.16/src/cpp/knetfile.c:521:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
				curr = read(fp->fd, (void*)((char*)buf + l), rest);
data/vcftools-0.1.16/src/cpp/knetfile.h:8:31:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
#define netread(fd, ptr, len) read(fd, ptr, len)
data/vcftools-0.1.16/src/cpp/variant_file.cpp:77:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		tmp_file.read(&tmp_char,sizeof(char));
data/vcftools-0.1.16/src/cpp/variant_file.cpp:84:11:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	tmp_file.read((char*)&POS,sizeof(POS));
data/vcftools-0.1.16/src/cpp/variant_file.cpp:89:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		tmp_file.read(&in_byte,sizeof(in_byte));
data/vcftools-0.1.16/src/cpp/variant_file.cpp:110:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		tmp_file.read(&tmp_char,sizeof(char));
data/vcftools-0.1.16/src/cpp/variant_file.cpp:117:11:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	tmp_file.read((char*)&POS,sizeof(POS));
data/vcftools-0.1.16/src/cpp/variant_file.cpp:120:11:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
	tmp_file.read((char*)&tmp_alleles,sizeof(tmp_alleles));
data/vcftools-0.1.16/src/cpp/variant_file.cpp:126:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		tmp_file.read(&in_byte,sizeof(in_byte));
data/vcftools-0.1.16/src/cpp/variant_file.cpp:132:12:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
		tmp_file.read(&in_byte,sizeof(in_byte));
data/vcftools-0.1.16/src/cpp/vcf_file.cpp:307: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).
			if ((strlen(gz_readbuffer) != gzMAX_LINE_LEN-1) || (gz_readbuffer[gzMAX_LINE_LEN-2] == '\n'))

ANALYSIS SUMMARY:

Hits = 251
Lines analyzed = 18881 in approximately 0.49 seconds (38695 lines/second)
Physical Source Lines of Code (SLOC) = 15558
Hits@level = [0]  15 [1]  28 [2] 198 [3]   3 [4]  22 [5]   0
Hits@level+ = [0+] 266 [1+] 251 [2+] 223 [3+]  25 [4+]  22 [5+]   0
Hits/KSLOC@level+ = [0+] 17.0973 [1+] 16.1332 [2+] 14.3335 [3+] 1.60689 [4+] 1.41406 [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.