From: Felipe Pena Date: Sat, 1 Aug 2009 18:22:31 +0000 (+0000) Subject: - Fixed bug #49132 (posix_times returns false without error) X-Git-Tag: php-5.2.11RC1~59 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=da73057c2ae900e47dc412d4a9672e8ab7c0e126;p=php - Fixed bug #49132 (posix_times returns false without error) patch by: phpbugs at gunnu dot us --- diff --git a/NEWS b/NEWS index d5c0869dab..ea9053aaa2 100644 --- a/NEWS +++ b/NEWS @@ -5,6 +5,8 @@ PHP NEWS defined as a file handle. (Ilia) - Fixed memory leak in stream_is_local(). (Felipe) +- Fixed bug #49132 (posix_times returns false without error). + (phpbugs at gunnu dot us) - Fixed bug #49074 (private class static fields can be modified by using reflection). (Jani) - Fixed bug #49052 (context option headers freed too early when using diff --git a/ext/posix/posix.c b/ext/posix/posix.c index 7e68503ef8..49e91ea56e 100644 --- a/ext/posix/posix.c +++ b/ext/posix/posix.c @@ -491,7 +491,7 @@ PHP_FUNCTION(posix_times) PHP_POSIX_NO_ARGS; - if((ticks = times(&t)) < 0) { + if ((ticks = times(&t)) == -1) { POSIX_G(last_error) = errno; RETURN_FALSE; }