php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #62584 error_reporting does not work as expected in php.ini
Submitted: 2012-07-17 08:18 UTC Modified: 2012-07-17 08:49 UTC
From: patpro at patpro dot net Assigned:
Status: Not a bug Package: *Configuration Issues
PHP Version: 5.4.4 OS: FreeBSD
Private report: No CVE-ID: None
 [2012-07-17 08:18 UTC] patpro at patpro dot net
Description:
------------
# php -v
PHP 5.4.4 (cli) (built: Jul  9 2012 00:15:41) 
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2012 Zend Technologies

Configure Command =>  './configure'  '--with-layout=GNU' '--localstatedir=/var' 
'--with-config-file-scan-dir=/usr/local/etc/php' '--
disable-all' '--enable-libxml' '--enable-mysqlnd' '--with-libxml-dir=/usr/local' 
'--with-pcre-regex=/usr/local' '--with-zlib-dir=/usr' 
'--program-prefix=' '--enable-fpm' '--with-fpm-user=www' '--with-fpm-group=www' 
'--with-apxs2=/usr/local/sbin/apxs' '--with-regex=php' 
'--with-zend-vm=CALL' '--prefix=/usr/local' '--mandir=/usr/local/man' '--
infodir=/usr/local/info/' '--build=amd64-portbld-freebsd8.1'
Server API => Command Line Interface


Configuring the error_reporting directive in php.ini to deactivate E_STRICT 
won't work unless you use the numerical form.
For example, this will not work:

error_reporting = E_ALL & ~E_DEPRECATED & ~E_STRICT

but this will work:

error_reporting = 5111

I can reproduce this problem on FreeBSD 8.2 and 8.1, running PHP 5.4.3 and PHP 
5.4.4. I have not tested this issue on another OS.

Expected result:
----------------
# php -r 'phpinfo();' | grep error_reporting
error_reporting => 5111 => 5111


Actual result:
--------------
# php -r 'phpinfo();' | grep error_reporting
error_reporting => 22527 => 22527


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-07-17 08:40 UTC] patpro at patpro dot net
Actually, it's fixed in 5.4.4. My bad.
 [2012-07-17 08:40 UTC] patpro at patpro dot net
-Status: Open +Status: Closed
 [2012-07-17 08:49 UTC] pajoye@php.net
not a bug.
 [2012-07-17 08:49 UTC] pajoye@php.net
-Status: Closed +Status: Not a bug
 
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Tue May 17 04:05:45 2022 UTC