Skip to content

Commit 815b4c7

Browse files
author
jef
committed
fix warning
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@14336 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent a785159 commit 815b4c7

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

src/mapserver/qgsfilter.cpp

+6-5
Original file line numberDiff line numberDiff line change
@@ -117,14 +117,15 @@ QgsFilter* QgsFilter::createFilterFromXml( const QDomElement& filterElem, QgsVec
117117
}
118118

119119
//get property index
120-
int attributeIndex;
120+
int attributeIndex = -1;
121121
if ( vl->dataProvider() )
122122
{
123123
attributeIndex = vl->dataProvider()->fieldNameIndex( attributeName );
124-
if ( attributeIndex == -1 )
125-
{
126-
return 0;
127-
}
124+
}
125+
126+
if ( attributeIndex == -1 )
127+
{
128+
return 0;
128129
}
129130

130131
//get literal value(s)

0 commit comments

Comments
 (0)