Boost logo

Boost Users :

From: Peteris Krumins [Newsgroups] (pknewsgroups_at_[hidden])
Date: 2006-06-09 21:51:48


Hello!

I am using a library which itself internally does not use any thread
sync mechanisms but it provides callback functions
lib_lock() and lib_unlock() which I can specify if the lib is used in
multithread environment.
lib_lock() would get called before critical segment and after it
lib_unlock() would get called.

I read Boost.Thread documentation and I understand that lock concept is
not thread-safe itself and should be used only at block scope.
This makes me think that I have no way to use locking provided by Boost
to acquire a lock in
lib_lock() function and release it in lib_unlock()? But I am not sure.

Do you have any suggestions if this can be done using Boost?

Thanks!
P.Krumins


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net