Commit 5bc420b
committed
Re-run getimagesize without source_info if false
Certain JPG images fail to get the $image_info variable when
$this->source_info is set in the getimagesize function if the exif data
is not what PHP is expecting. This ends up throwing exceptions instead
of letting them through as though they do not have exif data.
To allow valid images to make it through, we need to check to see if we
can retreive $image_info via getimagesize WITH $this->source_info, if
not (getimagesize returns FALSE), then get the $image_info without the
$this->source_info. Then it will fall back to throwing the
ImageResizeException if it still does not exist.1 parent 0496393 commit 5bc420b
2 files changed
+6
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | | - | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
81 | 83 | | |
82 | 84 | | |
83 | 85 | | |
| |||
0 commit comments