On Tue, May 12, 2009 at 4:09 PM, Eric Blossom <e...@comsec.com> wrote:

> On Tue, May 12, 2009 at 03:22:47PM -0400, Tom Lutz wrote:
> > I'm editing some of the .cc files and would like to know the preferred
> > method for performing thread synchronization in C++ code.  In particular,
> I
> > noticed that the set and get methods that are called on the
> gr_oscope_guts
> > class originate from a different thread then that of process_samples, and
> > this is causing problems for me.
> >
> > Thanks,
> > Tom
>
> Please use the boost mutexs:
>
>  #include <boost/thread.hpp>
>
>  boost::mutex  m;                      // the mutex
>
>  boost::mutex::scoped_lock guard(m)    // the scoped guard
>
> Eric


Thanks a bunch!
Tom
_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Reply via email to