Commit 6fc47fbb authored by Max Kellermann's avatar Max Kellermann

thread/Mutex: make ScopeLock an alias for std::unique_lock

parent 9c111842
...@@ -44,16 +44,7 @@ class Mutex : public PosixMutex {}; ...@@ -44,16 +44,7 @@ class Mutex : public PosixMutex {};
#endif #endif
class ScopeLock { using ScopeLock = std::unique_lock<Mutex>;
std::unique_lock<Mutex> lock;
public:
ScopeLock(Mutex &_mutex):lock(_mutex) {}
void Unlock() {
lock.unlock();
}
};
/** /**
* Within the scope of an instance, this class will keep a #Mutex * Within the scope of an instance, this class will keep a #Mutex
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment