Commit 51a8c109 authored by Max Kellermann's avatar Max Kellermann

thread/PosixMutex: fix indent

parent ea25e0ee
......@@ -36,25 +36,25 @@
* Low-level wrapper for a pthread_mutex_t.
*/
class PosixMutex {
pthread_mutex_t mutex;
pthread_mutex_t mutex;
public:
constexpr PosixMutex():mutex(PTHREAD_MUTEX_INITIALIZER) {}
constexpr PosixMutex():mutex(PTHREAD_MUTEX_INITIALIZER) {}
PosixMutex(const PosixMutex &other) = delete;
PosixMutex &operator=(const PosixMutex &other) = delete;
PosixMutex(const PosixMutex &other) = delete;
PosixMutex &operator=(const PosixMutex &other) = delete;
void lock() {
pthread_mutex_lock(&mutex);
}
void lock() {
pthread_mutex_lock(&mutex);
}
bool try_lock() {
return pthread_mutex_trylock(&mutex) == 0;
}
bool try_lock() {
return pthread_mutex_trylock(&mutex) == 0;
}
void unlock() {
pthread_mutex_unlock(&mutex);
}
void unlock() {
pthread_mutex_unlock(&mutex);
}
};
#endif
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