Fix for MT crashes in lcms
authorMichael Vrhel <michael.vrhel@artifex.com>
Wed, 18 May 2011 06:43:14 +0000 (23:43 -0700)
committerMichael Vrhel <michael.vrhel@artifex.com>
Wed, 18 May 2011 06:45:07 +0000 (23:45 -0700)
commit447c1a791d28fb72b196f75356bc411ef45afbdd
tree10307b292474c3f8f89c685eb9f542135a8d8e2b
parent8d9bc767c0c59a7effa7652cbcbde14ab82de249
Fix for MT crashes in lcms

It turns out that lcms is can not safely share
profiles between threads when creating links.  This
was fixed by placing a mutex lock around the profile
creation.  It also turns out that lcms can not
use the same link to do transformations between threads.
This was solved by disabling the shared cache between
the threads.  Finally there was a race condition in
reference counting the device ICC profile in the pdf14
device.  Also, this commit includes a fix for a memory
leak in the pdf_mask object in gdevp14.
gs/base/gdevp14.c
gs/base/gscms.h
gs/base/gsicc_cache.c
gs/base/gsicc_lcms.c
gs/base/gsicc_manage.c
gs/base/gxcldev.h
gs/base/gxclthrd.c
gs/base/lib.mak