I'm not the world's best socket programmer, nor am I completely up to capacity on a Saturday morning, but I don't understand the question. If you're already using
IO::Select or the four-argument
select, why do you need a non-blocking socket? Just provide a timeout.