certain jpeg header causes error in phpdatabase.php
Submitted by jiaping on Tue, 2008-01-22 01:13.
I've installed phpAlbum today. Everything is fine except that certain files cause some problems when scanning album directories.
The following error showed up when I clicked the 'scan directories now' link.
---------------
Parse error: syntax error, unexpected $end in .../phpdatabase.php(580) : runtime-created function on line 2
Fatal error: Call to undefined function: () in .../phpdatabase.php on line 705
----------------
I tried to remove all header info from the jpeg with 'jhead -purejpg' and uploaded the file again. The scan was successful.
I used ImageMagick to resize my large files. So I suppose the header was not touched during resizing. I didn't dig further, so I've no idea which header field is causing this problem.
Any idea?

If it is not private photo
If it is not private photo could you send me that problematic picture with header , or even very small size would be ok, 1x1 pixel, so nothing more is there only the header, I could then check it and fix the script so it can ignore it next time ...
Patrik
some update
Thank you Patrik, I just sent you two 1x1 pictures.
I just found out that loading original pictures (3000x2000, roughly) doesn't generate the error, although this size is too large for my server to handle. So I don't get errors (except no thumbnail and resized pictures). It seems that the ImageMagick resized ones have ill-formed header, no matter the resizing factor. But jhead, exiv2, and other image viewing applications (eog, gthumb) are happy with them. This behavior is not consistent. I got about 4 problematic pictures out of 30 resized ones. Version info of my ImageMagick: 6.2.4 10/02/07 Q16
Also worth noting is that my server doesn't have exif module enabled, so I believe it's not certain fields in exif that is causing the problem, but the whole header block is doing something evil.