Adding back the list > Does a GDALDriver know his own name? GetDescription from GDALMajorObject > maybe?
Yes, a GDALDriver knows its name. But the static method implemented by pfnOpen doesn't know which driver it comes from, so it doesn't set the poDriver member of the GDALDataset* it returns, and let that job to GDALOpen() itself. Which saves to do this in hundreds of drivers, and potentially forgetting to do it. > The problem is that there is a Driver abstraction object in the > Node.js bindings that supports opening a file through that driver. I > guess this is the reason the original author used pfnOpen. They should use GDALOpenEx() instead, which has an option to restrict the candidate driver(s). -- Spatialys - Geospatial professional services http://www.spatialys.com
_______________________________________________ gdal-dev mailing list [email protected] https://lists.osgeo.org/mailman/listinfo/gdal-dev
