Skip to content

Commit

Permalink
Cast poResult->int_value to int in OGRFeatureQuery::Evaluate().
Browse files Browse the repository at this point in the history
ogrfeaturequery.cpp:262:48: error: implicit conversion loses integer precision: 'GIntBig' (aka 'long long') to 'int' [-Werror,-Wshorten-64-to-32]


git-svn-id: https://svn.osgeo.org/gdal/trunk@35121 f0d54148-0727-0410-94bb-9a71ac55c965
  • Loading branch information
schwehr committed Aug 15, 2016
1 parent 15e7060 commit a8ecdd1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gdal/ogr/ogrfeaturequery.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ int OGRFeatureQuery::Evaluate( OGRFeature *poFeature )
if( poResult->field_type == SWQ_INTEGER ||
poResult->field_type == SWQ_INTEGER64 ||
poResult->field_type == SWQ_BOOLEAN )
bLogicalResult = CPL_TO_BOOL(poResult->int_value);
bLogicalResult = CPL_TO_BOOL(static_cast<int>(poResult->int_value));

delete poResult;

Expand Down

0 comments on commit a8ecdd1

Please sign in to comment.