Closed (works as designed)
Project:
IMCE
Version:
7.x-1.5
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
27 Jan 2012 at 14:48 UTC
Updated:
27 Jan 2012 at 16:58 UTC
Repeatable: Always
Steps to repeat:
php: return 'images_uploaded_by_users/'.$user->name;
Expected Results:
User sees imce file browser.
Actual Results:
The browser says that the connection has been interrupted by the server. Checking in the Apache Error Log showed a segmentation fault
I don't know exactly why, but the problem is caused by the eval in imce_process_directories() function. Anyway, this simple patch to imce.page.inc file solves the problem:
@@ -776,7 +776,8 @@
foreach ($directories as $directory) {
if (substr($directory['name'], 0, 4) == 'php:') {
- $directory['name'] = eval(substr($directory['name'], 4));
+ $directory_name = substr($directory['name'], 4);
+ $directory['name'] = eval($directory_name);
//php may return an array of directories
if (is_array($directory['name'])) {
foreach ($directory['name'] as $name) {
Comments
Comment #1
ufku commentedThis is probably an xdebug bug. Try updating it.
These could be related;
http://bugs.xdebug.org/view.php?id=586
https://bugs.php.net/bug.php?id=53479
Comment #2
antoniopironti commentedI've upgraded xdebug to the 2.1.3 version: all works fine now.
It seems that this bug affects only xdebug 2.0.5 : with xdebug 2.0.3 I haven't any problem.
Thank you very much for your quick reply and support.