Skip to content
Snippets Groups Projects
Commit c6811f5c authored by Anders Markvardsen's avatar Anders Markvardsen
Browse files

Merge remote-tracking branch 'origin/bugfix/9926_coverity_issues_mgigg'

parents 257d218b 8d1c3e48
No related branches found
No related tags found
No related merge requests found
......@@ -211,7 +211,6 @@ namespace Mantid
int number, udet, select, group;
double offset;
instrcalmap::const_iterator it;
std::string str;
while(getline(infile,str))
{
......@@ -219,10 +218,12 @@ namespace Mantid
continue;
std::istringstream istr(str);
istr >> number >> udet >> offset >> select >> group;
it=instrcalib.find(udet);
if (it==instrcalib.end()) // Not found, don't assign a group
group=0;
group=((*it).second).second; // If found then assign new group
instrcalmap::const_iterator it = instrcalib.find(udet);
if (it == instrcalib.end()) // Not found, don't assign a group
group = 0;
else
group=((*it).second).second; // If found then assign new group
// write out
writeCalEntry(outfile,number,udet,offset,select,group);
}
}
......
......@@ -264,7 +264,6 @@ namespace Mantid
int number, udet, select, group;
double offset;
instrcalmap::const_iterator it;
std::string str;
while(getline(infile,str))
{
......@@ -272,10 +271,12 @@ namespace Mantid
continue;
std::istringstream istr(str);
istr >> number >> udet >> offset >> select >> group;
it=instrcalib.find(udet);
if (it==instrcalib.end()) // Not found, don't assign a group
group=0;
group=((*it).second).second; // If found then assign new group
instrcalmap::const_iterator it = instrcalib.find(udet);
if (it == instrcalib.end()) // Not found, don't assign a group
group = 0;
else
group=((*it).second).second; // If found then assign new group
// write to file
writeCalEntry(outfile,number,udet,offset,select,group);
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment