ext/Yk/stl_tree_tz.h in YkESet-0.99.7 vs ext/Yk/stl_tree_tz.h in YkESet-0.99.9

- old
+ new

@@ -1746,10 +1746,14 @@ { _Link_type __y = static_cast<_Link_type>(_Rb_tree_rebalance_for_erase (const_cast<_Base_ptr>(__position._M_node), this->_M_impl._M_header)); - _M_destroy_node(__y); + if(__y->_TZ_refCount == 0){ + _M_destroy_node(__y); + }else{ + __y->prepareDestroy(&_Rb_tree_impl<_Compare>::destroyNode); + } --_M_impl._M_node_count; } template<typename _Key, typename _Val, typename _KeyOfValue, typename _Compare, typename _Alloc>