From 0c7bf5eed1eebf408ca701987c3c3bd10897df5b Mon Sep 17 00:00:00 2001 From: buslov Date: Wed, 15 Nov 2017 21:47:14 +0300 Subject: [PATCH] Fix V614 warning from PVS-Studio Static Analyzer Potentially uninitialized variable 'segannotindex' used. --- src/SNPs.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/SNPs.cpp b/src/SNPs.cpp index 4e45b9f..13e0f39 100644 --- a/src/SNPs.cpp +++ b/src/SNPs.cpp @@ -231,7 +231,7 @@ void SNPs::load_snps_z(string infile, vector prior, vector annot append_dannotnames(jname, dmodels[j]); } // get indices for segannot - int segannotindex; + int segannotindex = 0; if (segannot.size() > 0){ if (header_index.find(segannot[0]) == header_index.end()){ cerr << "ERROR: cannot find segment annotation "<< segannot[0] << "\n";