reraikes
(RonR)
December 9, 2015, 8:11pm
1
When installing FreePBX 2.11 + Asterisk 11.20.0 on Debian 8 (Jessie) instead of Debian 7 (Wheezy), I get a massive numbers of:
PHP Notice: Undefined offset: 8192 in /var/www/html/admin/libraries/utility.functions.php on line 383
What is this indicative of and what can be done to eliminate them?
jfinstrom
(James Finstrom)
December 9, 2015, 8:24pm
2
so the line
$txt = sprintf("%s] (%s:%s) - %s", $errortype[$errno], $errfile, $errline, $errstr);
known error types:
$errortype = array (
E_ERROR => 'ERROR',
E_WARNING => 'WARNING',
E_PARSE => 'PARSE_ERROR',
E_NOTICE => 'NOTICE',
E_CORE_ERROR => 'CORE_ERROR',
E_CORE_WARNING => 'CORE_WARNING',
E_COMPILE_ERROR => 'COMPILE_ERROR',
E_COMPILE_WARNING => 'COMPILE_WARNING',
E_USER_ERROR => 'USER_ERROR',
E_USER_WARNING => 'USER_WARNING',
E_USER_NOTICE => 'USER_NOTICE',
E_STRICT => 'RUNTIM_NOTICE',
E_RECOVERABLE_ERROR => 'CATCHABLE_FATAL_ERROR',
);
the error 8192 is E_DEPRECATED. which isn’t in the list above and is new as of PHP 5.3.0
jfinstrom
(James Finstrom)
December 9, 2015, 8:27pm
3
For PHP 5.3 you need FreePBX 12+
reraikes
(RonR)
December 9, 2015, 9:07pm
4
It appears PHP 5.4.45 is being installed under Debian 7 (Wheezy) -> No “Undefined offset: 8192:…” messages
It appears PHP 5.6.14 is being installed under Debian 8 (Jessie) -> Massive “Undefined offset: 8192:…” messages
What will be the effect of simply ignoring these messages under Debian 8 (Jessie)?
jfinstrom
(James Finstrom)
December 9, 2015, 9:17pm
5
If you are using a newer version of PHP I suggest you use 12+. Most things will probably be OK but you may run in to random issues and quirks that may affect usability and stability.
You can add
8192 => 'DEPRECATED_FUNCTION',
to the above array and see what the actual error is.
reraikes
(RonR)
December 9, 2015, 9:33pm
6
The 8192 errors are only occurring during the install of FreePBX 2.11 (not during the use of FreePBX 2.11).
It’s not clear to me how I would add:
8192 => ‘DEPRECATED_FUNCTION’,
to
/var/www/html/admin/libraries/utility.functions.php
during the install process.
reraikes
(RonR)
December 9, 2015, 9:47pm
7
Hold on…
I think I’ve figured out how to add the line with sed after the install archive has been extracted.
I’ll report back what I find.
reraikes
(RonR)
December 10, 2015, 2:07am
8
James,
With
8192 => ‘DEPRECATED_FUNCTION’,
added to the $errortype array as you suggested, there are no
PHP Notice: Undefined offset: 8192 in /var/www/html/admin/libraries/utility.functions.php on line 383
messages displayed. Given that, is it safe to assume this is an innocuous message that can be ignored?
Thanks,
Ron