问题
Currently I am developing a gateway to connect apns to push notification. Apns will close the ssl socket when the connection is idle for about one hour. Sometimes when I reconnect, boost.asio keep telling me that handshake fail with error code 335544539. When apns close the connection, I will call socket.close(), but I didn't shutdown ssl stream. How could I clean ssl stream so that I could reconnect by using the old ssl stream?
来源:https://stackoverflow.com/questions/25263381/how-to-clean-boostasiosslstream-after-closed-by-server