aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--goto.cpp3
-rw-r--r--rbtree.h2
-rw-r--r--undo.h2
3 files changed, 4 insertions, 3 deletions
diff --git a/goto.cpp b/goto.cpp
index 63ccc05..c64a896 100644
--- a/goto.cpp
+++ b/goto.cpp
@@ -36,9 +36,6 @@ class GotoTable : public RBTree {
run(void)
{
table->set(name, pc);
- g_free(name);
- name = NULL;
-
#ifdef DEBUG
table->dump();
#endif
diff --git a/rbtree.h b/rbtree.h
index f4831ce..bb3d8f4 100644
--- a/rbtree.h
+++ b/rbtree.h
@@ -21,6 +21,8 @@ public:
public:
RB_ENTRY(RBEntry) nodes;
+ virtual ~RBEntry() {}
+
inline RBEntry *
next(void)
{
diff --git a/undo.h b/undo.h
index a32d02a..32bb2d5 100644
--- a/undo.h
+++ b/undo.h
@@ -18,6 +18,8 @@ public:
gint pos;
+ virtual ~UndoToken() {}
+
virtual void run() = 0;
};