Close socks in context mgr