aboutsummaryrefslogtreecommitdiff
path: root/src/geodesic.c
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2017-02-28 01:02:25 +0100
committerEven Rouault <even.rouault@spatialys.com>2017-02-28 17:02:53 +0100
commit21d16428760469717fd25ebf9d03c286db935c66 (patch)
tree0747dd9d46c106e11a4e85d0caaacc002f2557e9 /src/geodesic.c
parent8bf1acf2692e7628c2a7b41ad53d876f9b9b09e9 (diff)
downloadPROJ-21d16428760469717fd25ebf9d03c286db935c66.tar.gz
PROJ-21d16428760469717fd25ebf9d03c286db935c66.zip
Enable cppcheck and fix related mostly false-positive warnings
Diffstat (limited to 'src/geodesic.c')
-rw-r--r--src/geodesic.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/geodesic.c b/src/geodesic.c
index 5c038a33..d93268c6 100644
--- a/src/geodesic.c
+++ b/src/geodesic.c
@@ -85,7 +85,10 @@ static void Init() {
tolb = tol0 * tol2;
xthresh = 1000 * tol2;
degree = pi/180;
- NaN = sqrt(-1.0);
+ {
+ double minus1 = -1.0;
+ NaN = sqrt(minus1);
+ }
init = 1;
}
}