Skip to content

Commit c19cc08

Browse files
committed
proj_trans(): set PROJ_ERR_COORD_TRANSFM_NO_OPERATION error when failing in ONLY_BEST=YES mode
1 parent fc456d9 commit c19cc08

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/4D_api.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -443,8 +443,10 @@ PJ_COORD proj_trans(PJ *P, PJ_DIRECTION direction, PJ_COORD coord) {
443443
} else if (P->errorIfBestTransformationNotAvailable ||
444444
P->warnIfBestTransformationNotAvailable) {
445445
warnAboutMissingGrid(alt.pj);
446-
if (P->errorIfBestTransformationNotAvailable)
446+
if (P->errorIfBestTransformationNotAvailable) {
447+
proj_errno_set(P, PROJ_ERR_COORD_TRANSFM_NO_OPERATION);
447448
return res;
449+
}
448450
P->warnIfBestTransformationNotAvailable = false;
449451
skipNonInstantiable = true;
450452
}

0 commit comments

Comments
 (0)