Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: help for accept sys call

by fokat (Deacon)
on Mar 05, 2005 at 16:02 UTC ( #436913=note: print w/ replies, xml ) Need Help??


in reply to help for accept sys call

(...) but many a times it returns some junk value. i do not know how is thsi happening.

And what is $GLOBAL_SERVER? What is that "junk value" that is being returned? I will assume that ->accept() is calling the perl's builtin accept().

If this supposition is correct, this snippet from perldoc -f accept might be enlightening:

accept NEWSOCKET,GENERICSOCKET
      Accepts an incoming socket connect, just as the accept(2) sys-
      tem call does. Returns the packed address if it succeeded,
      false otherwise. See the example in "Sockets: Client/Server
      Communication" in perlipc.

This "junk" could be the packed address of the client connecting to your socket. On the other hand, this might be IO::Socket->accept() instead of the builtin, so the earlier snippet would not apply directly...

Note that accept() can be interrupted by signals, so it may be returning undef. In any case, please provide a bit more of detail, so that we can properly help you.

Best regards

-lem, but some call me fokat


Comment on Re: help for accept sys call
Re^2: help for accept sys call
by Anonymous Monk on Mar 06, 2005 at 14:31 UTC
    actually this returns string like
    test0001 passed
    but many times it also returns
    testebug failed .
    actually it shouls return status of test just like in first case. when i submit tests like test0001 after they are complated it returns its status along with test name but i am wondering when i am not submitting any test case like testebug why it is returning it.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2014-09-24 04:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (245 votes), past polls