Edit report at http://bugs.php.net/bug.php?id=53409&edit=1

 ID:                 53409
 Updated by:         bj...@php.net
 Reported by:        webmaster at skarmflyg dot org
 Summary:            sleep() return NULL
-Status:             Closed
+Status:             Re-Opened
-Type:               Documentation Problem
+Type:               Bug
-Package:            Documentation problem
+Package:            Unknown/Other Function
-Operating System:   Windows XP
+Operating System:   pajoye
 PHP Version:        5.3.3
-Assigned To:        aharvey
+Assigned To:        pajoye
 Block user comment: N
 Private report:     N

 New Comment:

After quick discussion on IRC;

Windows does actually have a way to provide the same functionality as,
f.e., 

Linux by using SleepEx().



Re-classifying as php-src bug & assign to Pierre.


Previous Comments:
------------------------------------------------------------------------
[2010-11-26 10:19:25] ahar...@php.net

This bug has been fixed in the documentation's XML sources. Since the
online and downloadable versions of the documentation need some time
to get updated, we would like to ask you to be a bit patient.

Thank you for the report, and for helping us make our documentation
better.



------------------------------------------------------------------------
[2010-11-26 10:19:18] ahar...@php.net

Automatic comment from SVN on behalf of aharvey
Revision: http://svn.php.net/viewvc/?view=revision&revision=305764
Log: Fix doc bug #53409 (sleep() return NULL).

------------------------------------------------------------------------
[2010-11-25 23:57:52] paj...@php.net

Sleep on windows returns nothing as well as some other platforms.



The result of sleep is actually platform dependent (NULL/FALSE or
0/FALSE).

------------------------------------------------------------------------
[2010-11-25 22:45:15] webmaster at skarmflyg dot org

Description:
------------
---

>From manual page: http://www.php.net/function.sleep#Return Values

---

Sleep should return int or possibly boolean false but returns NULL.



Using 

PHP 5.3.3 

Apache 2.2.6

Windows XP SP3

Test script:
---------------
$x=sleep(1);

var_dump($x);  // Outputs NULL. Expected int 0.

Expected result:
----------------
According to documentation $x should be integer 0 or possibly false.

Actual result:
--------------
Variable $x becomes NULL.


------------------------------------------------------------------------



-- 
Edit this bug report at http://bugs.php.net/bug.php?id=53409&edit=1

Reply via email to