OSGeo / PROJ

PROJ - Cartographic Projections and Coordinate Transformations Library
https://proj.org
Other
1.72k stars 778 forks source link

[Lint] WKTParser::Private: refactor code a bit in the hope to fix false-positive 'Untrusted value as argument' Coverity Scan warning #4146

Closed rouault closed 4 months ago

rouault commented 4 months ago

Should hopefully fix CID 460619, 460620, 460621

Coverity Scan suddenly complains about propertyCount_ not being properly being validated (which is wrong). Let's take the opportunity to use a bit more C++ish style in the hope it will shut down that false positive.

QuLogic commented 4 months ago

Coverity Scan suddenly complains about numProperties_

Do you mean propertyCount_ here?

rouault commented 4 months ago

Do you mean propertyCount_ here?

yes, sorry. amended