mirror of
https://github.com/rbock/sqlpp11.git
synced 2024-11-15 20:31:16 +08:00
Add missing template parameter
This fixes a compiler error for C++11/14
This commit is contained in:
parent
490259ee69
commit
37739bd2d7
@ -90,7 +90,7 @@ namespace sqlpp
|
|||||||
template<typename ConnectionBase>
|
template<typename ConnectionBase>
|
||||||
typename connection_pool<ConnectionBase>::_pooled_connection_t connection_pool<ConnectionBase>::pool_core::get()
|
typename connection_pool<ConnectionBase>::_pooled_connection_t connection_pool<ConnectionBase>::pool_core::get()
|
||||||
{
|
{
|
||||||
std::unique_lock lock{_mutex};
|
std::unique_lock<std::mutex> lock{_mutex};
|
||||||
if (_handles.empty()) {
|
if (_handles.empty()) {
|
||||||
lock.unlock();
|
lock.unlock();
|
||||||
return _pooled_connection_t{_connection_config, this->shared_from_this()};
|
return _pooled_connection_t{_connection_config, this->shared_from_this()};
|
||||||
@ -108,7 +108,7 @@ namespace sqlpp
|
|||||||
template<typename ConnectionBase>
|
template<typename ConnectionBase>
|
||||||
void connection_pool<ConnectionBase>::pool_core::put(_handle_ptr_t& handle)
|
void connection_pool<ConnectionBase>::pool_core::put(_handle_ptr_t& handle)
|
||||||
{
|
{
|
||||||
std::unique_lock lock{_mutex};
|
std::unique_lock<std::mutex> lock{_mutex};
|
||||||
if (_handles.full ()) {
|
if (_handles.full ()) {
|
||||||
_handles.set_capacity (_handles.capacity () + 5);
|
_handles.set_capacity (_handles.capacity () + 5);
|
||||||
}
|
}
|
||||||
@ -118,7 +118,7 @@ namespace sqlpp
|
|||||||
template<typename ConnectionBase>
|
template<typename ConnectionBase>
|
||||||
std::size_t connection_pool<ConnectionBase>::pool_core::available()
|
std::size_t connection_pool<ConnectionBase>::pool_core::available()
|
||||||
{
|
{
|
||||||
std::unique_lock lock{_mutex};
|
std::unique_lock<std::mutex> lock{_mutex};
|
||||||
return _handles.size();
|
return _handles.size();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user