fix hang on socket session