[gdal-dev] Mutex around Proj.4

Even Rouault even.rouault at mines-paris.org
Sun May 9 05:19:29 EDT 2010


Kevin,

yes the mutex around proj.4 is necessary in order to guarantee correct 
behaviour when several threads call proj.4 concurrently.

There are a few places in proj.4 where global variables are used. One of them 
is the pj_errno variable / pj_strerrno() function.

There's an old discussion on the proj.4 mailing list about the issue : 
http://lists.maptools.org/pipermail/proj/2005-February/thread.html#1483 (and 
other following threads the same month)

I'd note that a few things have evolved : since proj 4.7.0, there is a locking 
mechanism within proj.4 that protects the init cache and the gridlist. But 
the pj_errno and maybe other issues remain.

Best regards,

Even


More information about the gdal-dev mailing list