Skip Menu |

This queue is for tickets about the Apache2-Imager-Resize CPAN distribution.

Report information
The Basics
Id: 99414
Status: new
Priority: 0/
Queue: Apache2-Imager-Resize

People
Owner: Nobody in particular
Requestors: m.bazalik [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: image enlarged even when enlarge param is not provided
Date: Fri, 10 Oct 2014 13:15:36 +0100
To: bug-Apache2-Imager-Resize [...] rt.cpan.org
From: Marian Bazalik <m.bazalik [...] gmail.com>
Hi there It seems Imager Resizer allows users to enlarge the image even when enlarge param is not present. This is due wrong condition in source code: # enlarge images only if the enlarge argument is set if ( not $args->{enlarge} and ( ( $scale{xpixels} and ($scale{xpixels} > $imgwidth) ) or ( $scale{ypixels} and ($scale{ypixels} > $imgheight) ) ) and ( ($args->{scale_type} ne 'min') or ( ( $scale{xpixels} and ($scale{xpixels} > $imgwidth) ) and ( $scale{ypixels} and ($scale{ypixels} > $imgheight) ) ) ) ) { %scale = (); } Where check is totally skiped when scaletype is set to ne and only one of width or height is present Example query is: ?w=10000&quality=1&scaletype=min Cheers Marian