in reply to Re: accept() on non-blocking socket still hangs
in thread accept() on non-blocking socket still hangs

I just tried using  fcntl(FH, F_SETFL, $flags | O_NONBLOCK);, but it gave me this error:

Your vendor has not defined Fcntl macro F_SETFL, used at server.pl line 20.

What do I do now? :-/

Replies are listed 'Best First'.
Re: Re: Re: accept() on non-blocking socket still hangs
by chromatic (Archbishop) on Mar 18, 2001 at 07:12 UTC
    You need to use the Fcntl module. Luckily, it's part of the core distribution. You might also look in perlopentut, under 'Opening Non-File Files'.

    Update: Move along, nothing to see here. My error is abundantly clear (He must have used Fcntl, which is why the fcntl() call didn't throw the error.) Oops.

      chromatic, the error:

      Your vendor has not defined Fcntl macro F_SETFL, used at server.pl line 20.

      means that Zip did use Fcntl and that it reported that F_SETFL was not defined on the platform in question (at the time that the module was compiled).

              - tye (but my friends call me "Tye")