Minor changes to socket