|
NetBurner 3.5.7
PDF Version |
RAII wrapper that combines an OS task lock with an OS_CRIT critical section. More...
#include <nbrtos.h>
Public Member Functions | |
| OSLockAndCritObj (OS_CRIT &ocrit) | |
| Construct the object, lock the OS, and enter the critical section. | |
| ~OSLockAndCritObj () | |
| Destruct the object, leave the critical section, and unlock the OS. | |
RAII wrapper that combines an OS task lock with an OS_CRIT critical section.
On construction, calls LockAndEnter() on the provided OS_CRIT object, which prevents task switching and claims the critical section. On destruction, calls LeaveAndUnlock() to release both the critical section and the task lock.
|
inline |