Fix a prof_tctx_t destruction race.