Skip to content

Commit 581ec9f

Browse files
committed
msProjectionsDiffer(): restrict attempts normalization with proj.4
1 parent 8501873 commit 581ec9f

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

mapproject.c

+5-1
Original file line numberDiff line numberDiff line change
@@ -1132,7 +1132,11 @@ int msProjectionsDiffer( projectionObj *proj1, projectionObj *proj2 )
11321132
int ret;
11331133

11341134
ret = msProjectionsDifferInternal(proj1, proj2);
1135-
if( ret )
1135+
if( ret &&
1136+
/* to speed up things, do normalization only if one proj is */
1137+
/* likely of the form init=epsg:XXX and the other proj=XXX datum=YYY... */
1138+
( (proj1->numargs == 1 && proj2->numargs > 1) ||
1139+
(proj1->numargs > 1 && proj2->numargs == 1) ) )
11361140
{
11371141
projectionObj* p1normalized;
11381142
projectionObj* p2normalized;

0 commit comments

Comments
 (0)