fix crash on manual reconnect after connection loss