From 9990608a8f73ad884aa1b21bc76a3c6fb44d3382 Mon Sep 17 00:00:00 2001 From: Frank Warmerdam Date: Fri, 17 Feb 2006 02:26:14 +0000 Subject: ERANGE/EDOM treated as transient errors git-svn-id: http://svn.osgeo.org/metacrs/proj/trunk@1323 4e78687f-474d-0410-85f9-8d5e500ac6b2 --- src/pj_transform.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/pj_transform.c b/src/pj_transform.c index 4934914f..55ed8431 100644 --- a/src/pj_transform.c +++ b/src/pj_transform.c @@ -30,6 +30,9 @@ ****************************************************************************** * * $Log$ + * Revision 1.16 2006/02/17 02:26:14 fwarmerdam + * ERANGE/EDOM treated as transient errors + * * Revision 1.15 2005/12/04 14:47:37 fwarmerdam * use symbolic names as per patch from Martin Vermeer * @@ -209,8 +212,9 @@ int pj_transform( PJ *srcdefn, PJ *dstdefn, long point_count, int point_offset, geodetic_loc = pj_inv( projected_loc, srcdefn ); if( pj_errno != 0 ) { - if( pj_errno > 0 || pj_errno < -44 || point_count == 1 - || transient_error[-pj_errno] == 0 ) + if( (pj_errno != 33 /*EDOM*/ && pj_errno != 34 /*ERANGE*/ ) + && (pj_errno > 0 || pj_errno < -44 || point_count == 1 + || transient_error[-pj_errno] == 0 ) ) return pj_errno; else { @@ -304,8 +308,9 @@ int pj_transform( PJ *srcdefn, PJ *dstdefn, long point_count, int point_offset, projected_loc = pj_fwd( geodetic_loc, dstdefn ); if( pj_errno != 0 ) { - if( pj_errno > 0 || pj_errno < -44 || point_count == 1 - || transient_error[-pj_errno] == 0 ) + if( (pj_errno != 33 /*EDOM*/ && pj_errno != 34 /*ERANGE*/ ) + && (pj_errno > 0 || pj_errno < -44 || point_count == 1 + || transient_error[-pj_errno] == 0 ) ) return pj_errno; else { -- cgit v1.2.3