From: Byron Jones Date: Tue, 19 Mar 2013 16:15:33 +0000 (+0800) Subject: Bug 852445: Mime type detection truncates the first 32 bytes from attachments X-Git-Tag: bugzilla-4.5.1~187 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a9f2bb677b5f721ad0c47b52cdf35fca11c64d2d;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 3678424c95..df1a11fccc 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; }