make DETACH-SOCKET be a function, not a condition