diff options
author | lpsolit%gmail.com <> | 2009-08-13 23:32:15 +0200 |
---|---|---|
committer | lpsolit%gmail.com <> | 2009-08-13 23:32:15 +0200 |
commit | 6eec197b4ad9d396b6c33c5012155608ae4bd961 (patch) | |
tree | aed084eef9a536fb859f1d68684b4dd554293bf8 /Bugzilla/Attachment.pm | |
parent | fcbd202edcd0f5b53bad398aa4a1f515ba25d16d (diff) | |
download | bugzilla-6eec197b4ad9d396b6c33c5012155608ae4bd961.tar.gz bugzilla-6eec197b4ad9d396b6c33c5012155608ae4bd961.tar.xz |
Bug 480986: The BMP -> PNG conversion tool for new attachments should be an extension - Patch by Frédéric Buclin <LpSolit@gmail.com> r/a=mkanat
Diffstat (limited to 'Bugzilla/Attachment.pm')
-rw-r--r-- | Bugzilla/Attachment.pm | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/Bugzilla/Attachment.pm b/Bugzilla/Attachment.pm index 5ba62e5e5..b1aecd5b0 100644 --- a/Bugzilla/Attachment.pm +++ b/Bugzilla/Attachment.pm @@ -568,24 +568,6 @@ sub _check_data { return $data if ref $data; $data || ThrowUserError('zero_length_file'); - - # This should go away, see bug 480986. - # Windows screenshots are usually uncompressed BMP files which - # makes for a quick way to eat up disk space. Let's compress them. - # We do this before we check the size since the uncompressed version - # could easily be greater than maxattachmentsize. - if (Bugzilla->params->{'convert_uncompressed_images'} - && $params->{mimetype} eq 'image/bmp') - { - require Image::Magick; - my $img = Image::Magick->new(magick=>'bmp'); - $img->BlobToImage($data); - $img->set(magick=>'png'); - my $imgdata = $img->ImageToBlob(); - $data = $imgdata; - $params->{mimetype} = 'image/png'; - } - # Make sure the attachment does not exceed the maximum permitted size. my $len = length($data); my $max_size = $params->{store_in_file} ? Bugzilla->params->{'maxlocalattachment'} * 1048576 |