ImageBrowser unrecoverably broken after uploading big image

pescetti - March 13, 2009 - 16:29
Project:Image Browser
Version:6.x-1.0-beta1
Component:Code
Category:bug report
Priority:normal
Assigned:Starnox
Status:closed
Description

If I upload the attached image (a 110 KByte JPEG, 4000x3000) in ImageBrowser called from FCKEditor, PHP memory limits are exceeded by some underlying module.

Unfortunately, ImageBrowser cannot handle the situation: it reports "An HTTP 0 error occurred" upon upload and then it stops working completely: if I close the ImageBrowser window and reopen it, I only get a blank page.

My error log shows:
[error] [client ...] PHP Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 16000 bytes) in .../includes/image.gd.inc on line 190, referer: ...imagebrowser/view/browser&app=FCKEditor

Even if does not depend on ImageBrowser, could it be possible to die more gracefully and ignore the faulty image somehow?

I use a PHP memory_limit of 64M, which is a generous limit on shared hosting. Anyway, whatever the limit is set to (even if I set it to the 96 MBytes suggested by ImageAPI) uploading a very big image will break ImageBrowser, which is quite undesirable.

#1

pescetti - March 13, 2009 - 16:32

Attaching a sample image which breaks ImageBrowser.

AttachmentSize
imagebrowser-test-4000x3000.jpg 110.5 KB

#2

Starnox - May 23, 2009 - 10:23
Priority:normal» critical

Thanks I will look into this.

#3

jthorson - July 5, 2009 - 19:35

Definately a show-stopper for my sites ...

Any progress to report?

Incidently, once I tried to upload the large image, I got the garbage output reported in http://drupal.org/node/486730.

#4

Starnox - July 5, 2009 - 19:50

Sure I did look into it but couldn't locate where it was falling over, as it often changes in the debug process.

It's possible that the error lies in the one of the modules IB relies on. i.e. image, image api etc.

#5

Starnox - July 11, 2009 - 02:04
Priority:critical» normal
Assigned to:Anonymous» Starnox

Ok just tested this in v2 which I have been working on tonight, and good news the whole module won't bail out now. v2 no longer relies on 'Image' module so that must have been part of the issue.

Just need to tidy up a few more things but looks like we will have this one fixed when version 2 comes out.

#6

Starnox - July 12, 2009 - 14:24

Issue opened here as the fatal error happens within ImageAPI.

#516920: Better error handling?

#7

Starnox - October 13, 2009 - 14:21
Status:active» closed

Not much I can do until that issue gets fixed.

 
 

Drupal is a registered trademark of Dries Buytaert.