diff options
| author | Thomas Knudsen <busstoptaktik@users.noreply.github.com> | 2018-02-12 16:45:09 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-02-12 16:45:09 +0100 |
| commit | f1dd367c64de4f48eb48f6dcf17c2be93c7eaafc (patch) | |
| tree | d506bdb3f140af97421c0bc1a851be3a149f4e2b /src/pj_init.c | |
| parent | a557b49e85ebfbfe0af076bc529002ca60e4a045 (diff) | |
| download | PROJ-f1dd367c64de4f48eb48f6dcf17c2be93c7eaafc.tar.gz PROJ-f1dd367c64de4f48eb48f6dcf17c2be93c7eaafc.zip | |
Avoid invalid ellps error messages from pj_init (#794)
Reset error type PJD_ERR_MAJOR_AXIS_NOT_GIVEN for operations
that do not need an ellipsoid.
Diffstat (limited to 'src/pj_init.c')
| -rw-r--r-- | src/pj_init.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/pj_init.c b/src/pj_init.c index bf098686..78486480 100644 --- a/src/pj_init.c +++ b/src/pj_init.c @@ -600,6 +600,8 @@ pj_init_ctx(projCtx ctx, int argc, char **argv) { return pj_default_destructor (PIN, proj_errno(PIN)); } else { + if (PJD_ERR_MAJOR_AXIS_NOT_GIVEN==proj_errno (PIN)) + proj_errno_reset (PIN); PIN->f = 1.0/298.257223563; PIN->a_orig = PIN->a = 6378137.0; PIN->es_orig = PIN->es = PIN->f*(2-PIN->f); |
