Re: reading socket stream with timeout

2005-05-10 Thread $Bill Luebkert
Foo Ji-Haw wrote: > You mean trapping signals? ActivePerl can trap the usual like Ctrl-C. > But I don't know how well supported it is there. No such thing as a signal in Windoze (at least not in the UNIX sense). What they do when you type like a CTRL-C is create a new thread in the process and

Re: reading socket stream with timeout

2005-05-09 Thread Foo Ji-Haw
You mean trapping signals? ActivePerl can trap the usual like Ctrl-C. But I don't know how well supported it is there. David Nicol wrote: On 5/7/05, Foo Ji-Haw <[EMAIL PROTECTED]> wrote: Great idea. Will check that out as well. Thanks. But as a technical question, has anyone faced such a probl

Re: reading socket stream with timeout

2005-05-09 Thread David Nicol
On 5/7/05, Foo Ji-Haw <[EMAIL PROTECTED]> wrote: > Great idea. Will check that out as well. Thanks. > > But as a technical question, has anyone faced such a problem? If so, how > do you resolve this? alarm 5; $SIG{ALRM} = sub {what to do when the alrm happens}; works with cygperl but not activepe

Re: reading socket stream with timeout

2005-05-06 Thread Foo Ji-Haw
Great idea. Will check that out as well. Thanks. But as a technical question, has anyone faced such a problem? If so, how do you resolve this? Brian Raven wrote: Foo Ji-Haw wrote: Hello guys, I seem to be stuck with this one. Need your expert input on this. I used a IO::Socket::INET object to

RE: reading socket stream with timeout

2005-05-06 Thread Brian Raven
Foo Ji-Haw wrote: > Hello guys, > > I seem to be stuck with this one. Need your expert input on this. > > I used a IO::Socket::INET object to connect to a whois server (port > 43, and no I'm not trying to parse emails to spam!). I send the > domain name and read back the whois information. Inform

Re: reading socket stream with timeout

2005-05-06 Thread Foo Ji-Haw
Thanks for the tip. Sounds like a good idea. Only problem with turning off blocking, is that i slept (actually my program does) for 5 sec, but nothing happened. I don't even know if sleeping 'spoils' the reading of the input stream... But i will try. Thanks. $Bill Luebkert wrote: Foo Ji-Haw wrot

Re: reading socket stream with timeout

2005-05-06 Thread $Bill Luebkert
Foo Ji-Haw wrote: > Hello guys, > > I seem to be stuck with this one. Need your expert input on this. > > I used a IO::Socket::INET object to connect to a whois server (port 43, > and no I'm not trying to parse emails to spam!). I send the domain name > and read back the whois information. Inf

reading socket stream with timeout

2005-05-06 Thread Foo Ji-Haw
Hello guys, I seem to be stuck with this one. Need your expert input on this. I used a IO::Socket::INET object to connect to a whois server (port 43, and no I'm not trying to parse emails to spam!). I send the domain name and read back the whois information. Information is returned as a series o