Commit 8903b0e5 authored by Maciej (Matthew) Piechotka's avatar Maciej (Matthew) Piechotka
Browse files

Fix memory leak in TreeSet and TreeMap

parent 64abd710
......@@ -127,6 +127,10 @@ public class Gee.TreeMap<K,V> : Gee.AbstractBidirSortedMap<K,V> {
this.value_equal_func = value_equal_func;
}
~TreeMap () {
clear ();
}
private void rotate_right (ref Node<K, V> root) {
Node<K,V> pivot = (owned) root.left;
pivot.color = root.color;
......
......@@ -71,6 +71,10 @@ public class Gee.TreeSet<G> : AbstractBidirSortedSet<G> {
this.compare_func = compare_func;
}
~TreeSet () {
clear ();
}
/**
* {@inheritDoc}
*/
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment