diff options
| author | Even Rouault <even.rouault@spatialys.com> | 2018-03-12 22:26:15 +0100 |
|---|---|---|
| committer | Even Rouault <even.rouault@spatialys.com> | 2018-03-14 18:51:50 +0100 |
| commit | 0223e2517eef43e0e6955408a1aef89d2d981983 (patch) | |
| tree | 66c2a32905dc9edc289489c540d4454e9bedb113 /src/geodesic.c | |
| parent | 0682897c358c41f21871ef87001d4825b3076784 (diff) | |
| download | PROJ-0223e2517eef43e0e6955408a1aef89d2d981983.tar.gz PROJ-0223e2517eef43e0e6955408a1aef89d2d981983.zip | |
geodesic.c: initialize various variables to please CLang Static Analyzer
Diffstat (limited to 'src/geodesic.c')
| -rw-r--r-- | src/geodesic.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/geodesic.c b/src/geodesic.c index a7e4376a..5121ea98 100644 --- a/src/geodesic.c +++ b/src/geodesic.c @@ -1894,7 +1894,7 @@ void geod_polygon_addedge(const struct geod_geodesic* g, struct geod_polygon* p, real azi, real s) { if (p->num) { /* Do nothing is num is zero */ - real lat, lon, S12 = 0; /* Initialize S12 to stop Visual Studio warning */ + real lat = 0, lon = 0, S12 = 0; /* Initialize S12 to stop Visual Studio warning */ geod_gendirect(g, p->lat, p->lon, azi, GEOD_LONG_UNROLL, s, &lat, &lon, 0, 0, 0, 0, 0, p->polyline ? 0 : &S12); @@ -2031,7 +2031,7 @@ unsigned geod_polygon_testedge(const struct geod_geodesic* g, tempsum = p->A[0]; crossings = p->crossings; { - real lat, lon, s12, S12; + real lat = 0, lon = 0, s12, S12 = 0; geod_gendirect(g, p->lat, p->lon, azi, GEOD_LONG_UNROLL, s, &lat, &lon, 0, 0, 0, 0, 0, &S12); |
