Apply https://github.com/LearnBoost/socket.io/pull/688