aboutsummaryrefslogtreecommitdiff
path: root/src/zenbase/include
diff options
context:
space:
mode:
authorDan Engelbrecht <[email protected]>2023-12-14 04:16:25 -0500
committerGitHub <[email protected]>2023-12-14 10:16:25 +0100
commit4d96ef4d9d2c35243a25d90949d43d0997e3bb44 (patch)
tree5f398e0027886aed3d12b625b89014ef83fb8abd /src/zenbase/include
parent0.2.37-pre1 (diff)
downloadzen-4d96ef4d9d2c35243a25d90949d43d0997e3bb44.tar.xz
zen-4d96ef4d9d2c35243a25d90949d43d0997e3bb44.zip
Make sure IoBuffer is a valid null-buffer after move operation (#610)
Diffstat (limited to 'src/zenbase/include')
-rw-r--r--src/zenbase/include/zenbase/refcount.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/zenbase/include/zenbase/refcount.h b/src/zenbase/include/zenbase/refcount.h
index 3afcf467c..6ad49cba2 100644
--- a/src/zenbase/include/zenbase/refcount.h
+++ b/src/zenbase/include/zenbase/refcount.h
@@ -107,6 +107,8 @@ public:
Rhs.m_Ref = nullptr;
}
+ inline void Swap(RefPtr& Rhs) noexcept { std::swap(m_Ref, Rhs.m_Ref); }
+
private:
T* m_Ref = nullptr;
template<typename U>