Hi,
We seem to be getting a lot of array_merge errors being logged from the plugins.php file:
===============
[Fri Aug 07 15:48:47.939843 2015] [:error] [pid 9211] [client 141.163.50.11:45982] PHP Warning: array_merge(): Argument #1 is not an array in /var/www/html/xerte/plugins.php on line 46
[Fri Aug 07 15:48:47.939895 2015] [:error] [pid 9211] [client 141.163.50.11:45982] PHP Warning: Invalid argument supplied for foreach() in /var/www/html/xerte/plugins.php on line 48
===============
It seems that the arrays for the array merge are not checked for 'false' values, and if that occurs then a null array is not used instead. A quick patch is:
--- plugins.php.orig 2015-07-29 23:17:23.000000000 +0100
+++ plugins.php 2015-08-07 16:32:39.358388665 +0100
@@ -41,8 +41,10 @@
* Only looks in PLUGINS_PATH and one dir underneath.
* Only loads files ending in .php
*/
-$files1 = glob(PLUGINS_PATH . D_S . '**' . D_S . '*.php');
+$files1 = glob(PLUGINS_PATH . D_S . '*' . D_S . '*.php');
+if ($files1 === false) $files1 = array();
$files2 = glob(PLUGINS_PATH . D_S . '*.php');
+if ($files2 === false) $files2 = array();
$files = array_merge($files1, $files2);
foreach ($files as $file) {
I also changed the '**' to a single asterisk for files1. Not sure why '**' was used.
John.