+ // this is called from API/CLI, so the world is stopped here
+ // it's safe to manipulate arbitrary per-thread data
+ u32 thread_index = nat_value_get_thread_index (&value);
+ tnm = vec_elt_at_index (nm->per_thread_data, thread_index);
+ u32 session_index = nat_value_get_session_index (&value);
+ if (pool_is_free_index (tnm->sessions, session_index))