added missing import socket statement