Fix an unused variable warning from scanbuild.
This commit is contained in:
parent
a4a1b729c6
commit
e680d43d7d
|
@ -26,14 +26,12 @@ bool cmSetTestsPropertiesCommand
|
||||||
|
|
||||||
// first collect up the list of files
|
// first collect up the list of files
|
||||||
std::vector<std::string> propertyPairs;
|
std::vector<std::string> propertyPairs;
|
||||||
bool doingFiles = true;
|
|
||||||
int numFiles = 0;
|
int numFiles = 0;
|
||||||
std::vector<std::string>::const_iterator j;
|
std::vector<std::string>::const_iterator j;
|
||||||
for(j= args.begin(); j != args.end();++j)
|
for(j= args.begin(); j != args.end();++j)
|
||||||
{
|
{
|
||||||
if(*j == "PROPERTIES")
|
if(*j == "PROPERTIES")
|
||||||
{
|
{
|
||||||
doingFiles = false;
|
|
||||||
// now loop through the rest of the arguments, new style
|
// now loop through the rest of the arguments, new style
|
||||||
++j;
|
++j;
|
||||||
if (std::distance(j, args.end()) % 2 != 0)
|
if (std::distance(j, args.end()) % 2 != 0)
|
||||||
|
@ -44,15 +42,9 @@ bool cmSetTestsPropertiesCommand
|
||||||
propertyPairs.insert(propertyPairs.end(), j, args.end());
|
propertyPairs.insert(propertyPairs.end(), j, args.end());
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
else if (doingFiles)
|
|
||||||
{
|
|
||||||
numFiles++;
|
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
this->SetError("called with illegal arguments, maybe "
|
numFiles++;
|
||||||
"missing a PROPERTIES specifier?");
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(propertyPairs.empty())
|
if(propertyPairs.empty())
|
||||||
|
@ -62,7 +54,6 @@ bool cmSetTestsPropertiesCommand
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// now loop over all the targets
|
// now loop over all the targets
|
||||||
int i;
|
int i;
|
||||||
for(i = 0; i < numFiles; ++i)
|
for(i = 0; i < numFiles; ++i)
|
||||||
|
|
Loading…
Reference in New Issue