1//
2// RWLock_POSIX.cpp
3//
4// Library: Foundation
5// Package: Threading
6// Module: RWLock
7//
8// Copyright (c) 2004-2006, Applied Informatics Software Engineering GmbH.
9// and Contributors.
10//
11// SPDX-License-Identifier: BSL-1.0
12//
13
14
15#include "Poco/RWLock_POSIX.h"
16
17
18namespace Poco {
19
20
21RWLockImpl::RWLockImpl()
22{
23 if (pthread_rwlock_init(&_rwl, NULL))
24 throw SystemException("cannot create reader/writer lock");
25}
26
27
28RWLockImpl::~RWLockImpl()
29{
30 pthread_rwlock_destroy(&_rwl);
31}
32
33
34} // namespace Poco
35