Merge Jc2k's rewrite of _soft_disconnect