Glib bindings now thread-safe

today's Glib commit adds the necessary locking to make the perl bindings
thread-safe.  perl's data structures should already be safe for calls from
multiple interpreters and possibly multiple interpreter threads (though i
haven't tried this), and this patch helps protect us from maniacs who call
perl methods and callbacks from multiple processor threads. :-)

thanks go to Brett Kosinski for contributing the initial patch and bugging me
about it, which he needed for work on GStreamer bindings.

for those worried about performance hits from the locking, you can disable the
threadsafety stuff by including the text "disable-threads" in the Makefile.PL
command line.  it also will be disabled if you don't have gthread-2.0 or if
your glib was built without thread safety turned on.  well, i should say, it
attempts to do this; i couldn't test that last situation.

muppet <scott at asofyet dot org>

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]