Skip to content

Commit d193dbc

Browse files
committed
CModule: update move constructor
1 parent 53b5365 commit d193dbc

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

include/dynlibutils/module.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ class CModule : public CMemory
293293

294294
CModule(const CModule&) = delete;
295295
CModule& operator=(const CModule&) = delete;
296-
CModule(CModule&& other) noexcept = default;
296+
CModule(CModule&& other) noexcept : CMemory(std::exchange(static_cast<CMemory &>(other), DYNLIB_INVALID_MEMORY)), m_sPath(std::move(other.m_sPath)), m_vecSections(std::move(other.m_vecSections)), m_pExecutableSection(std::move(other.m_pExecutableSection)) {}
297297
CModule(const CMemory pModuleMemory);
298298
explicit CModule(const std::string_view svModuleName);
299299
explicit CModule(const char* pszModuleName) : CModule(std::string_view(pszModuleName)) {}

0 commit comments

Comments
 (0)