[gdal-dev] bug in ogrct.cpp?

Alan Stewart astewart at terragotech.com
Fri Feb 13 09:08:39 PST 2015


I'm building 1.11.0 as a DLL on Windows with CPL_MULTIPROC_WIN32 and
USE_WIN32_MUTEX defined. Everything builds fine, but in my workflow a debug
build always fails while the release build succeeds. I'm using a modified
version of gdalwarp.cpp as a function linked into the DLL instead of as a
standalone executable.

The reason for the debug failure is the sole CPLAssert() in ogrct.cpp. It is commented out in the snippet below. The snippet begins at line 876 of the source file. Once commented out the debug version of my workflow seems to work fine, raising the question of the need for this assertion? I don't  know enough about ogrct.cpp or the CPL mutex to be confident about my decision to ignore it. Can anyone comment?

/* -------------------------------------------------------------------- */
/*      Do the transformation using PROJ.4.                             */
/* -------------------------------------------------------------------- */
    if( !bIdentityTransform && pjctx == NULL )
    {
        /* The mutex has already been created */
        //CPLAssert(hPROJMutex != NULL);
        CPLAcquireMutex(hPROJMutex, 1000.0);
    }

TIA,

Alan Stewart
Senior Software Engineer
TerraGo Technologies
3200 Windy Hill Road, Suite 1550W
Atlanta, GA 30339 USA
O.  +1 678.391.9615

www.terragotech.com<applewebdata://B24C0762-C7C9-4431-8518-ACC915448B89/www.terragotech.com>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20150213/9bb2b67a/attachment.html>


More information about the gdal-dev mailing list