aboutsummaryrefslogtreecommitdiff
path: root/backend/Object.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'backend/Object.cpp')
-rw-r--r--backend/Object.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/backend/Object.cpp b/backend/Object.cpp
new file mode 100644
index 0000000..300e6ac
--- /dev/null
+++ b/backend/Object.cpp
@@ -0,0 +1,15 @@
+#include <stdlib.h>
+
+#include "Object.h"
+
+Object::~Object() {
+ if (this->name != nullptr) {
+ free(const_cast<char *>(this->name));
+ this->name = nullptr;
+ }
+ if (this->description != nullptr) {
+ free(const_cast<char *>(this->description));
+ this->description = nullptr;
+ }
+}
+