diff --git a/src/cubescript.cc b/src/cubescript.cc index 656d564..597b5a4 100644 --- a/src/cubescript.cc +++ b/src/cubescript.cc @@ -419,7 +419,7 @@ LIBCUBESCRIPT_EXPORT void cs_state::destroy() { a->get_value().force_none(); static_cast(a)->clean_code(); } - p_state->destroy(i); + p_state->destroy(i->p_impl); } p_state->destroy(p_state->strman); p_state->destroy(static_cast(p_errbuf));