From: Byron Jones Date: Tue, 19 Mar 2013 16:16:29 +0000 (+0800) Subject: Bug 852445: Mime type detection truncates the first 32 bytes from attachments X-Git-Tag: bugzilla-4.4~27 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0f188afa98b5683293501fb3cca72a8988cbcc66;p=thirdparty%2Fbugzilla.git Bug 852445: Mime type detection truncates the first 32 bytes from attachments r=LpSolit,r=LpSolit --- diff --git a/Bugzilla/Attachment.pm b/Bugzilla/Attachment.pm index e7e707b985..380ef3d4cf 100644 --- a/Bugzilla/Attachment.pm +++ b/Bugzilla/Attachment.pm @@ -546,6 +546,7 @@ sub _check_content_type { } my $mimetype = mimetype($fh); + $fh->seek(0, 0); $content_type = $mimetype if $mimetype; }