home / blog

Mythweb broken in Ubuntu 12.10 [solved]

HTTP 500s when trying to visit mythweb after upgrade to 12.10.

Cause, removal of allow-call-time-pass-reference option in PHP 5.4

adam@brimstone$ tail -f /var/log/apache2/error.log

[Sun Dec 02 16:59:29 2012] [error] [client 10.5.1.63] PHP Fatal error:  Call-time pass-by-reference has been removed in /usr/share/mythtv/bindings/php/MythBase.php on line 50

[Sun Dec 02 17:03:53 2012] [error] [client 10.5.1.63] PHP Fatal error:  Call-time pass-by-reference has been removed in /usr/share/mythtv/mythweb/includes/sorting.php on line 122

Fix:

// before MythBase.php: line 50
Cache::setObject($this->cacheKey, &$this, $this->cacheLifetime);
// after
Cache::setObject($this->cacheKey, $this, $this->cacheLifetime);
// before sorting.php on line 122
$response = $function(&$a, &$b);
// after
$response = $function($a, $b);
This entry was posted in geek and tagged , . Bookmark the permalink.

Leave a Reply

Your email address will not be published.