mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-19 18:45:52 +00:00
Fix SharedPtr commit bug again
This commit is contained in:
@@ -225,7 +225,7 @@ public:
|
|||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
// Acquire a reference to u for the caller if not null.
|
// Acquire a reference to u for the caller.
|
||||||
//
|
//
|
||||||
template <class U>
|
template <class U>
|
||||||
static T* acquire (U* u) noexcept
|
static T* acquire (U* u) noexcept
|
||||||
@@ -235,12 +235,11 @@ private:
|
|||||||
return u;
|
return u;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Release a reference to t if not null.
|
static void release (T* t)
|
||||||
//
|
|
||||||
static void release (T* t) noexcept
|
|
||||||
{
|
{
|
||||||
if (t != nullptr)
|
if (t != nullptr)
|
||||||
t->decReferenceCount ();
|
if (t->decReferenceCount (false))
|
||||||
|
ContainerDeletePolicy <T>::destroy (t);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Swap ownership of the currently referenced object.
|
// Swap ownership of the currently referenced object.
|
||||||
|
|||||||
Reference in New Issue
Block a user