in reply to Re: Shared memory and asynchronous access
in thread Shared memory and asynchronous access

When i first saw this i wondered what select was doing in there, with empty texts for RBITS,WBITS,EBITS even. Then i realized it was just a sub-second sleep. is that correct?

Second i wondered what empty text strings would do to select. Didnt try it, but http://perldoc.perl.org/functions/select.html suggests this select(undef, undef, undef, 0.001); instead.

Replies are listed 'Best First'.
Re^3: Shared memory and asynchronous access
by BrowserUk (Patriarch) on Apr 06, 2017 at 06:58 UTC
    Then i realized it was just a sub-second sleep. is that correct?

    Yes.

    http://perldoc.perl.org/functions/select.html suggests this select(undef, undef, undef, 0.001); instead.

    Indeed. The empty strings version is just less typing; and appears to have no measurable affect on the functionality.


    With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority". The enemy of (IT) success is complexity.
    In the absence of evidence, opinion is indistinguishable from prejudice.
Re^3: Shared memory and asynchronous access
by marto (Cardinal) on Apr 06, 2017 at 08:09 UTC