Quantcast
Channel: Multithreading and Critical Sections Use - C++ - Stack Overflow
Browsing all 3 articles
Browse latest View live

Answer by Pete Kirkham for Multithreading and Critical Sections Use - C++

Use a C++ wrapper around the critical section which supports RAII:{ CriticalSectionLock lock ( mutex_ ); Do stuff...}The constructor for the lock acquires the mutex and the destructor releases the...

View Article



Answer by John Dibling for Multithreading and Critical Sections Use - C++

If you share a resource across threads, and some of those threads read while others write, then it must be protected always.It's hard to give any more advice without knowing more about your code, but...

View Article

Multithreading and Critical Sections Use - C++

I'm a little confused as to the proper use of critical sections in multithreaded applications. In my application there are several objects (some circular buffers and a serial port object) that are...

View Article
Browsing all 3 articles
Browse latest View live




Latest Images