From 5f62492b9cf22ebd6261a60ca069c85cd495668c Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Thu, 26 May 2016 10:46:19 +0200 Subject: [PATCH] fix PHP Warning: Parameter 2 to patch_header() expected to be a reference, value given --- doc/rpm-build/post_install.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/doc/rpm-build/post_install.php b/doc/rpm-build/post_install.php index d6462c02cb..81be6c9286 100755 --- a/doc/rpm-build/post_install.php +++ b/doc/rpm-build/post_install.php @@ -401,7 +401,10 @@ else // get user from header and replace password, as we dont know it $old_password = patch_header($config['header'],$config['config_user'],$config['config_passwd']); // register a shutdown function to put old password back in any case - register_shutdown_function('patch_header',$config['header'],$config['config_user'],$old_password); + register_shutdown_function(function() use (&$config, $old_password) + { + patch_header($config['header'], $config['config_user'], $old_password); + }); // update egroupware $setup_update = $setup_cli.' --update '.escapeshellarg('all,'.$config['config_user'].','.$config['config_passwd'].',,'.$config['install-update-app']);