Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#3287 closed defect (fixed)

Subdataset overview filenames stored with absolute path making them non-portable

Reported by: gaopeng Owned by: warmerdam
Priority: normal Milestone: 1.7.0
Component: GDAL_Raster Version: 1.6.1
Severity: normal Keywords: overviews subdatsets
Cc:

Description (last modified by warmerdam)

The issue is that the OVERVIEW_FILE value saved out is a local absolute path, which can be broken if the base image is accessed via UNC path.

For example, a local path like:

E:\Temp\Kabul_uncompressed\other\08MAY18184148-P1BS-005765570010_02_P002.NTF_0.ovr

is saved as OVERVIEW_FILE, and when the image is accessed using a UNC path on a network,


rberger\temp\Kabul_uncompressed\other\08MAY18184148-P1BS-005765570010_02_P002.NTF

the ovr path E:\Temp\... is not valid.

It also makes it unnecessarily difficult to move filesets around.

Change History (3)

comment:1 by warmerdam, 14 years ago

Description: modified (diff)
Owner: changed from Warmerdam to warmerdam
Status: newassigned
Summary: Broken overview (ovr) pathSubdataset overview filenames stored with absolute path making them non-portable

comment:2 by warmerdam, 14 years ago

Milestone: 1.6.41.7.0
Resolution: fixed
Status: assignedclosed

This has been fixed in trunk (r18321,r18322), and 1.6-esri (r18323) as well as a minimal test in hdf5.py.

The approach is store OVERVIEW_FILE with a :::BASE::: prefix with the filename and to replace that with the path of the physical file when using it. The substitution is handled by gdalpamdataset.cpp as it has access to the physical filename, but some of the handling is also in gdaldefaultoverviews.cpp.

comment:3 by warmerdam, 14 years ago

Keywords: overviews subdatsets added
Note: See TracTickets for help on using tickets.