On further testing, it appears that this is due to bug #784978, the
attached patch will have better performance for images not in the
database though, as it won't have to determine it doesn't exist through
filesystem level functions.
** Visibility changed to: Public
** This bug is no longer flagged as a security vulnerability
** Changed in: mahara
Importance: Critical => Low
** Changed in: mahara
Assignee: (unassigned) => Hugh Davenport (hugh-catalyst)
--
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
https://bugs.launchpad.net/bugs/992930
Title:
When an image artefact isn't present in the database, getimagesize is
called on a directory
Status in Mahara ePortfolio:
In Progress
Bug description:
in /thumb.php, line 75, a call to get_dataroot_image with the fileid argument
as the result of get_field.
If the database doesn't contain this entry, then get_field will return false.
in /lib/file.php, line 478 (get_dataroot_image), the $id argument is assumed
to be an int, and the variable
$originalimage is created using this variable, which results in a directory
path instead of a filename if $id==false.
On line 525, the $originalimage variable is used in a call to getimagesize,
which stalls a bit, then throws the following:
"PHP Notice: getimagesize(): Read error!" and outputs a stacktrace to the
error log.
This bug resulted in severely increased load on a clients 1.2
instance, which made their webserver unusable. This bug is also
present on 1.5. A patch is attached
To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/992930/+subscriptions
_______________________________________________
Mailing list: https://launchpad.net/~mahara-contributors
Post to : [email protected]
Unsubscribe : https://launchpad.net/~mahara-contributors
More help : https://help.launchpad.net/ListHelp