Skip to content

Commit 5403c05

Browse files
committed
修复CString没有析构函数的问题
1 parent 67c61d5 commit 5403c05

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

aurshine/ayr/base/CString.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ namespace ayr
3030

3131
CString(CString&& other) noexcept : str(other.str) { other.str = nullptr; }
3232

33+
~CString() { ayr_delloc(str); }
34+
3335
CString& operator=(const CString& other)
3436
{
3537
if (this == &other) return *this;

0 commit comments

Comments
 (0)