Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: How do I do a non-blocking accept?

by davidnicol (Acolyte)
on Aug 23, 2004 at 01:46 UTC ( #384997=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
      foreach (@Listeners){
       vec($rout,fileno($_),1) or next;
    ...
       while (accept(my $NewServer, $_)){
          push @Clients, $NewServer
          
    
  2. or download this
      foreach (@Listeners){
       vec($rout,fileno($_),1) or next;
    ...
          push @Clients, $NewServer
       }else{ log "accept: $!" }
          
    
  3. or download this
      foreach (@Listeners){
       vec($rout,fileno($_),1) or next;
    ...
       select($rvec,undef,undef,0);
       vec($rvec,fileno($_),1) and goto acc;
          
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://384997]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (11)
As of 2015-07-06 10:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (71 votes), past polls