mirror of
https://github.com/zeldaret/tp
synced 2026-05-23 15:01:53 -04:00
2453c0e333
* move dolsdk2004 over * cleanup some temp work * finish and cleanup gf * b_bh done * d_a_e_mb done
20 lines
371 B
C++
20 lines
371 B
C++
#ifndef JASCRITICALSECTION_H
|
|
#define JASCRITICALSECTION_H
|
|
|
|
#include <dolphin/os.h>
|
|
|
|
/**
|
|
* @ingroup jsystem-jaudio
|
|
*
|
|
*/
|
|
class JASCriticalSection {
|
|
public:
|
|
JASCriticalSection() { mInterruptState = OSDisableInterrupts(); };
|
|
~JASCriticalSection() { OSRestoreInterrupts(mInterruptState); };
|
|
|
|
private:
|
|
u32 mInterruptState;
|
|
};
|
|
|
|
#endif /* JASCRITICALSECTION_H */
|