fixes to socket server