restore shellslash state properly