Re: [PHP-DEV] Optional nowait argument to sem_acquire

[email protected] ("[email protected]")
Newsgroups php.internals
Message-ID <CAFp73XtV475nndwuwbtCu+6wO+CO7KkxfcxbUXz7Ya5it6odBQ@mail.gmail.com>
Hi,

Since I don't know where you guys like to discuss implementations, I'm
pasting same thing I did in php-src PR:

 I'd propose instead of accepting "nowait" only, I'd use a better support
and accept "until", dealing with possible cases:

   - -1: Blocks and wait until lock is acquired
   - 0: Exactly what your patch does, attempt to grab and if it fails, just
   return false (I'd remove the E_WARNING)
   - > 0: Acceptable time in milliseconds it would wait until consider the
   acquire failed


Cheers,



On Tue, Sep 2, 2014 at 8:50 AM, Matteo Beccati <[email protected]> wrote:

> Hi everyone,
>
> the following patch:
>
> https://github.com/php/php-src/pull/741
>
> has been lying around somewhere on my box since years and I recently
> stumbled upon it.
>
> However 5.6 was already RC and Ferenc suggested to eventually wait for
> 5.6.1.
>
> Do you think it's ok to add such a minor feature to 5.6.1?
>
>
> Cheers
> --
> Matteo Beccati
>
> Development & Consulting - http://www.beccati.com/
>
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


-- 
Guilherme Blanco
MSN: [email protected]
GTalk: guilhermeblanco
Toronto - ON/Canada
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.