From: Antony Dovgal Date: Fri, 23 Feb 2007 16:21:31 +0000 (+0000) Subject: fix #40606 (umask is not being restored when request is finished) X-Git-Tag: RELEASE_1_0_1~177 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=72c8da0695cf8282458eec08a50bf170124d05ad;p=php fix #40606 (umask is not being restored when request is finished) --- diff --git a/ext/standard/file.c b/ext/standard/file.c index b4471d2d79..664e4da72d 100644 --- a/ext/standard/file.c +++ b/ext/standard/file.c @@ -1581,7 +1581,7 @@ PHP_FUNCTION(umask) oldumask = umask(077); - if (BG(umask) != -1) { + if (BG(umask) == -1) { BG(umask) = oldumask; }