Skip to content

Commit

Permalink
Merge 318dab0 into 5d6945e
Browse files Browse the repository at this point in the history
  • Loading branch information
rouault committed Apr 20, 2019
2 parents 5d6945e + 318dab0 commit 51bd4b7
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/projections/omerc.cpp
Expand Up @@ -154,6 +154,8 @@ PJ *PROJECTION(omerc) {
phi1 = pj_param(P->ctx, P->params, "rlat_1").f;
lam2 = pj_param(P->ctx, P->params, "rlon_2").f;
phi2 = pj_param(P->ctx, P->params, "rlat_2").f;
if (fabs(phi1) > M_HALFPI || fabs(phi2) > M_HALFPI)
return pj_default_destructor(P, PJD_ERR_LAT_LARGER_THAN_90);
if (fabs(phi1 - phi2) <= TOL ||
(con = fabs(phi1)) <= TOL ||
fabs(con - M_HALFPI) <= TOL ||
Expand Down
10 changes: 10 additions & 0 deletions test/gie/builtins.gie
Expand Up @@ -4013,6 +4013,16 @@ operation +proj=omerc +lat_1=0.8 +a=6400000 +b=.4
-------------------------------------------------------------------------------
expect failure errno invalid_eccentricity

-------------------------------------------------------------------------------
operation +proj=omerc +lat_1=91
-------------------------------------------------------------------------------
expect failure errno lat_larger_than_90

-------------------------------------------------------------------------------
operation +proj=omerc +lat_2=91
-------------------------------------------------------------------------------
expect failure errno lat_larger_than_90


===============================================================================
Ortelius Oval
Expand Down

0 comments on commit 51bd4b7

Please sign in to comment.