[BUG #8481] improved handler disposal check