[Osgeo4w-trac] [osgeo4w] #876: saga 9.7.1-1 fails to start (MSVCP140.dll error)
OSGeo4W
trac_osgeo4w at osgeo.org
Mon Mar 31 05:22:29 PDT 2025
#876: saga 9.7.1-1 fails to start (MSVCP140.dll error)
------------------------+----------------------------
Reporter: andreaerdna | Owner: osgeo4w-dev@…
Type: defect | Status: new
Priority: critical | Component: Package
Version: | Resolution:
Keywords: |
------------------------+----------------------------
Comment (by andreaerdna):
On my system, saga 9.5.1-1 (GDAL/OGR 3.9) and previous ones work, while
saga 9.7.1-1 (GDAL/OGR 3.10) not; grass 8.4.0-2 (GDAL/OGR 3.9) and
previous ones work, while 8.4.0-5 or 8.4.1-1 (GDAL/OGR 3.10) not;
untwine.exe and pdal_wrench.exe in QGIS <= 3.40.2 (GDAL/OGR 3.9) work,
while in QGIS >= 3.40.3 (GDAL/OGR 3.10) not.
It looks like there is an issue for some applications built with a newer
version of msvcp140 when they are run on system with some previous
versions of msvcp140, see https://developercommunity.visualstudio.com/t
/Builds-against-MSVC-Redistributable-144/10690723?sort=newest, and the
issue is due to a change in mutex contructor in VS 2022 17.10
https://developercommunity.visualstudio.com/t/Access-violation-in-
_Thrd_yield-after-up/10664660#T-N10668856.
In fact, renaming all the msvcp* dlls in bin folder in order to force also
QGIS and other libraries to use the msvcp* dlls available in the system,
even executing gdalinfo --version in the OSGeo4W shell crashes
(MSVCP140.DLL) after reporting the GDAL version, and QGIS crashes when it
is closed:
{{{
Stack Trace
mtx_do_lock mutex.cpp:103
CPLODBCDriverInstaller::RemoveDriver :
CPLODBCDriverInstaller::RemoveDriver :
CPLODBCDriverInstaller::RemoveDriver :
CPLODBCDriverInstaller::RemoveDriver :
QgsApplication::exitQgis :
QgisApp::~QgisApp :
QList::operator+= :
main :
BaseThreadInitThunk :
RtlUserThreadStart :
}}}
So... maybe the issue has been is actually triggered by GDAL/OGR 3.10
build.
See also https://github.com/OSGeo/gdal/pull/10224 and
https://github.com/OSGeo/gdal/commit/5a9ef441292b5a92ab58fe54a9fcdab5b1e58bdd
--
Ticket URL: <https://trac.osgeo.org/osgeo4w/ticket/876#comment:7>
OSGeo4W <http://trac.osgeo.org/osgeo4w>
OSGeo4W is the Windows installer and package environment for the OSGeo stack.
More information about the Osgeo4w-trac
mailing list