summaryrefslogtreecommitdiff
path: root/program/lib/Roundcube
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2014-10-24 19:08:21 +0200
committerAleksander Machniak <alec@alec.pl>2014-10-24 19:08:21 +0200
commit2979df5529f987e548d9f970d6e7731f3affa965 (patch)
tree09a8d61863a0765a4cca9e5072156fd4de2878ac /program/lib/Roundcube
parent9d0d40308c79218419e24d3d118f4bcf09df059b (diff)
Call exif_read_data() only on JPEG images
Diffstat (limited to 'program/lib/Roundcube')
-rw-r--r--program/lib/Roundcube/rcube_image.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/program/lib/Roundcube/rcube_image.php b/program/lib/Roundcube/rcube_image.php
index d0d0c7437..77ce1647d 100644
--- a/program/lib/Roundcube/rcube_image.php
+++ b/program/lib/Roundcube/rcube_image.php
@@ -229,7 +229,7 @@ class rcube_image
$image = $new_image;
// fix rotation of image if EXIF data exists and specifies rotation (GD strips the EXIF data)
- if ($this->image_file && function_exists('exif_read_data')) {
+ if ($this->image_file && $type == 'jpg' && function_exists('exif_read_data')) {
$exif = exif_read_data($this->image_file);
if ($exif && $exif['Orientation']) {
switch ($exif['Orientation']) {