Skip to content

Commit

Permalink
Merge pull request #4926 from OSGeo/backport-4924-to-release/3.4
Browse files Browse the repository at this point in the history
[Backport release/3.4] KEA: print error message when opening of kea file fails
  • Loading branch information
rouault committed Dec 1, 2021
2 parents 4017c38 + 355ae69 commit 1788cd2
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion gdal/frmts/kea/keadataset.cpp
Expand Up @@ -151,9 +151,12 @@ GDALDataset *KEADataset::Open( GDALOpenInfo * poOpenInfo )

return pDataset;
}
catch (const kealib::KEAIOException &)
catch (const kealib::KEAIOException &e)
{
// was a problem - can't be a valid file
CPLError( CE_Failure, CPLE_OpenFailed,
"Attempt to open file `%s' failed. Error: %s\n",
poOpenInfo->pszFilename, e.what() );
return nullptr;
}
}
Expand Down

0 comments on commit 1788cd2

Please sign in to comment.