aboutsummaryrefslogtreecommitdiff
path: root/src/geodesic.c
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2018-03-12 22:26:15 +0100
committerEven Rouault <even.rouault@spatialys.com>2018-03-14 18:51:50 +0100
commit0223e2517eef43e0e6955408a1aef89d2d981983 (patch)
tree66c2a32905dc9edc289489c540d4454e9bedb113 /src/geodesic.c
parent0682897c358c41f21871ef87001d4825b3076784 (diff)
downloadPROJ-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.c4
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);