问题
Didn't change anything lately but I started to get the infamouse PHP Fatal error: Invalid opcode 153/1/8
a small php -v showed:
PHP 5.3.3-7+squeeze17 with Suhosin-Patch (cli) (built: Aug 23 2013 15:06:16)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v1.0-dev, Copyright (c) 2004-2012 eAccelerator, by eAccelerator
To be honest, I wasn't aware we used eAccelerator before. I think the hoster upgraded php or changed something in php.ini because I'm sure I didn't touch the code meanwhile..
Anyway my question is: since the Fatal error is shown on the line where I have:
uasort($tabWsFull, function($a, $b) {
return $b['bk'] - $a['bk'];
});
Is there something I can do to fix from within the code ? (without deactivating eAcceleator) maybe rewriting the uasort function ?
All the help is welcome, thx for all.
回答1:
I am not sure but still try
function mySort($a,$b){
return $b['bk'] - $a['bk'];
}
uasort($tabWsFull,'mySort');
来源:https://stackoverflow.com/questions/20841026/invalide-opcode-and-php-sort-function