add version variable & time to close sockets