Opened 12 years ago

Closed 11 years ago

#2161 closed defect (fixed)

CPLError in VSI Open/Read Causing problems.

Reported by: warmerdam Owned by: warmerdam
Priority: normal Milestone:
Component: default Version: svn-trunk
Severity: normal Keywords: vsi
Cc: dron tamas

Description

Recent changes (primarily r13539 and r13538) modify VSIFOpen(), VSIFOpenL() and read/write functions in some contexts to issue CPLError() calls if they fail.

This causes a variety of problems. Most notably many autotest suite tests fail because CPL errors are getting set and not cleared and later triggering python exceptions or other failures.

Basically, the current application expectation is that VSI functions should not directly issues errors themselves. Changing this assumption ripples through the system.

Change History (3)

comment:1 Changed 12 years ago by warmerdam

Status: newassigned

I have #ifdef'ed out the low level errors in trunk as r13549.

Andrey - I think we need to discuss your rationale for the changes (which I believe is to minimize or remove errno use above the vsi level) and whether there are other acceptable solutions. I am not keen on the current approach.

comment:2 Changed 12 years ago by warmerdam

Andrey,

Have you resolved this? Is there still anything outstanding or can the ticket be closed?

comment:3 Changed 11 years ago by dron

Resolution: fixed
Status: assignedclosed

The problem was solved and CPLError's do not used anymore in VSI* functions. Instead the errno variable is properly saved and restored when needed.

Note: See TracTickets for help on using tickets.