This issue will be extremely difficult to fix. Good chance it remains open for some time: https://github.com/OSGeo/gdal/issues/13961