Opened 15 years ago

Closed 13 years ago

#3200 closed defect (fixed)

HDF4 driver sometimes not opening file with description matching passed in filename

Reported by: warmerdam Owned by: warmerdam
Priority: normal Milestone: 1.9.0
Component: GDAL_Raster Version: unspecified
Severity: normal Keywords: HDF4
Cc:

Description

Hi,

When I import a HDF file with gdal, I've this error:

A dataset opened by GDALOpenShared should have the same filename.....

GRASS 6.4.0RC5 (wgs84_lat_long):~ > i.in.spotvgt -a --overwrite --verbose
file=/media/Archivio_Esterno/DE_archivio/cartografia/satellite/spot_vegetation_Africa/V1KRNS10__19980401_NDVI__Africa/0001/0001_NDV.HDF
rast=ndvi_test
Importing SPOT VGT NDVI map...
Warning 6: A dataset opened by GDALOpenShared should have the same filename
(/media/Archivio_Esterno/DE_archivio/cartografia/satellite/spot_vegetation_Africa/V1KRNS10__19980401_NDVI__Africa/0001/0001_NDV.HDF)
and description
(HDF4_SDS:UNKNOWN:"/media/Archivio_Esterno/DE_archivio/cartografia/satellite/spot_vegetation_Africa/V1KRNS10__19980401_NDVI__Africa/0001/0001_NDV.HDF":0) 

---

This warning is issued because the driver is returning the dataset with a description that does not match the filename passed into GDALOpenShared(). This means future attempts to open the dataset with GDALOpenShared() will not get the same dataset handle since without matching filenames it cannot identify that they are the same. The HDF4 driver should, if possible, try to avoid this situation though it is a non-critical issue, only impeding effective dataset handle sharing.

Change History (1)

comment:1 by Even Rouault, 13 years ago

Milestone: 1.9.0
Resolution: fixed
Status: newclosed

r22774 /trunk/gdal/frmts/hdf4/hdf4dataset.cpp: HDF4: set description to be the passed filename to avoid warning (#3200)

Note: See TracTickets for help on using tickets.