This was a problem I fought for a long time. There is a (relatively) simple solution here:
http://arduino.cc/forum/index.php?topic=49401.0Or, you can do something similar directly in the connect logic in the library. That will make upgrading the IDE tougher when you want to move forward though. I modified the library back in version 21 to support a timeout on the connect(), and it drove me nuts when I wanted to move to IDE 1.0+
There is a similar problem with the DNS lookup, but the solution is different. When you run into that problem, the answer is on this board somewhere as well.