mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-15 16:38:54 +00:00
Updated the sleep() manual page to reflect the new Windows behaviour by
reintegrating some of the old return values text, adding a specific note based on how SleepEx() is documented to behave on Windows, and adding a Changelog section to document the pre-5.3.4 behaviour. git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@305811 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
c870a589e3
commit
6ef46c971e
1 changed files with 33 additions and 8 deletions
|
@ -37,16 +37,15 @@
|
|||
<refsect1 role="returnvalues">
|
||||
&reftitle.returnvalues;
|
||||
<para>
|
||||
On all platforms, <function>sleep</function> returns &false; if the
|
||||
<parameter>seconds</parameter> parameter is invalid.
|
||||
Returns zero on success, or &false; on error.
|
||||
</para>
|
||||
<para>
|
||||
On Windows, provided the aforementioned <parameter>seconds</parameter>
|
||||
parameter is valid, <function>sleep</function> always returns &null;.
|
||||
</para>
|
||||
<para>
|
||||
On other platforms, <function>sleep</function> returns zero on success, or
|
||||
the number of seconds left to sleep if interrupted by a signal.
|
||||
If the call was interrupted by a signal, <function>sleep</function> returns
|
||||
a non-zero value. On Windows, this value will always be
|
||||
<literal>192</literal> (the value of the
|
||||
<constant>WAIT_IO_COMPLETION</constant> constant within the Windows API).
|
||||
On other platforms, the return value will be the number of seconds left to
|
||||
sleep.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -58,6 +57,32 @@
|
|||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="changelog">
|
||||
&reftitle.changelog;
|
||||
<para>
|
||||
<informaltable>
|
||||
<tgroup cols="2">
|
||||
<thead>
|
||||
<row>
|
||||
<entry>&Version;</entry>
|
||||
<entry>&Description;</entry>
|
||||
</row>
|
||||
</thead>
|
||||
<tbody>
|
||||
<row>
|
||||
<entry>5.3.4</entry>
|
||||
<entry>
|
||||
Before PHP 5.3.4, on Windows, <function>sleep</function> always
|
||||
returns &null; when sleep has occurred, regardless of whether the
|
||||
sleep was interrupted or not.
|
||||
</entry>
|
||||
</row>
|
||||
</tbody>
|
||||
</tgroup>
|
||||
</informaltable>
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="examples">
|
||||
&reftitle.examples;
|
||||
<para>
|
||||
|
|
Loading…
Reference in a new issue