[cl-gd-devel] thread safety in cl-gd
Alain Picard
Alain.Picard at memetrics.com
Fri Jul 27 06:02:04 UTC 2007
Dear all,
I'm wondering if cl-gd has been thoroughly tested for
thread safety? I've experienced a couple of segfaults
here and there, apparently at random, in libgd.
Cursory inspection of the code seems to suggest, for instance,
that *transfomers* is not safe; the only references to this variable
I see are in specials.lisp:
(defvar *transformers* nil
"Stack of currently active transformer objects.")
and in WITH-TRANFORMATION, which does not create a new binding
for *transformers*, but rather just pushes a new transformation
onto the global *transformers*.
Am I reading this right? It seems to me that two different
lispworks threads could run in such a way so that 1 thread
inadvertently starts running with transformers that another thread
establishes then gets swapped out.
Comments?
Alain Picard
--
Please read about why Top Posting
is evil at: http://en.wikipedia.org/wiki/Top-posting
and http://www.dickalba.demon.co.uk/usenet/guide/faq_topp.html
Please read about why HTML in email is evil at: http://www.birdhouse.org/etc/evilmail.html
More information about the Cl-gd-devel
mailing list