From ade24c7e355cf65874d10c9d72bb7710919b0084 Mon Sep 17 00:00:00 2001 From: Felipe Pena Date: Sat, 1 Aug 2009 18:22:31 +0000 Subject: [PATCH] - Fixed bug #49132 (posix_times returns false without error) patch by: phpbugs at gunnu dot us --- NEWS | 2 ++ ext/posix/posix.c | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 04aac2ea40..644debe55a 100644 --- a/NEWS +++ b/NEWS @@ -8,6 +8,8 @@ PHP NEWS - Fixed signature generation/validation for zip archives in ext/phar. (Greg) - Fixed memory leak in stream_is_local(). (Felipe) +- Fixed bug #49132 (posix_times returns false without error). + (phpbugs at gunnu dot us) - Fixed bug #49092 (ReflectionFunction fails to work with functions in fully qualified namespaces). (Kalle, Jani) - Fixed bug #49074 (private class static fields can be modified by using diff --git a/ext/posix/posix.c b/ext/posix/posix.c index 0c4db8bb1e..4a5198956e 100644 --- a/ext/posix/posix.c +++ b/ext/posix/posix.c @@ -651,7 +651,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; } -- 2.40.0