diff --git a/panda/src/pgraph/transformState.cxx b/panda/src/pgraph/transformState.cxx index 4d02425683..fc8b3de606 100644 --- a/panda/src/pgraph/transformState.cxx +++ b/panda/src/pgraph/transformState.cxx @@ -96,6 +96,10 @@ TransformState:: // true now, probably we've been double-deleted. nassertv(get_ref_count() == 0); _cache_stats.add_num_states(-1); + +#ifndef NDEBUG + _flags = F_is_invalid | F_is_destructing; +#endif } /**