Ticket #4295 (closed enhancement: fixed)
Support of user-data in CPLErrorHandler
|Reported by:||mloskot||Owned by:||warmerdam|
Currently, CPLErrorHandler is a dumb stateless function call that causes certain class of inconveniences and difficulties to users. Especially C++ users who want to make use of...C++ concepts like functors.
Here is a simple patch that tries to deal with imperfection of errors callback mechanism in GDAL. Perhaps it could be considered for GDAL 2.0.
With this patch, users can easily use apply trampoline (thunk) called to achieve flexibility in callbacks dispatching.