Prevents assertion during fast logout + login

Fixes #347