k0pp: (1) check the last line of that first while: "last;" - so no, it's NOT an infinite loop.
(2) hmm, perhaps you should look again: use IO::Socket; use warnings; use strict;
(3) perhaps not everyone is advanced enough to PoCo or simply doesn't want to use it. i know that was the case for me when i wrote old bots.