diff options
| author | Thomas Knudsen <busstoptaktik@users.noreply.github.com> | 2017-10-10 07:46:25 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-10-10 07:46:25 +0200 |
| commit | bda07af30000acd0b870e014848ab41e59fda945 (patch) | |
| tree | 390207dc2427cbd4e62bfdb17482093b65dcaed5 /src | |
| parent | d4e6ed566b7de7ab8999b8c21616951a72482c95 (diff) | |
| parent | 0333785b7d89b3af154793b4f4bb939e1bdaf731 (diff) | |
| download | PROJ-bda07af30000acd0b870e014848ab41e59fda945.tar.gz PROJ-bda07af30000acd0b870e014848ab41e59fda945.zip | |
Merge pull request #596 from busstoptaktik/OSS-Fuzz-issue-3595
Resolve OSS Fuzz issue 3595 division by zero by replacing atan(y/x) with atan2(y,x)
Credit to OSS Fuzz
Diffstat (limited to 'src')
| -rw-r--r-- | src/geocent.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/geocent.c b/src/geocent.c index e340e73d..a8cec043 100644 --- a/src/geocent.c +++ b/src/geocent.c @@ -430,7 +430,7 @@ void pj_Convert_Geocentric_To_Geodetic (GeocentricInfo *gi, while (SDPHI*SDPHI > genau2 && iter < maxiter); /* ellipsoidal (geodetic) latitude */ - *Latitude=atan(SPHI/fabs(CPHI)); + *Latitude=atan2(SPHI, fabs(CPHI)); return; #endif /* defined(USE_ITERATIVE_METHOD) */ |
