Skip Menu |

This queue is for tickets about the PDF-Reuse CPAN distribution.

Report information
The Basics
Id: 104874
Status: resolved
Priority: 0/
Queue: PDF-Reuse

People
Owner: cnighs [...] cpan.org
Requestors: TPLA [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 0.36
Fixed in: 0.36_04



Subject: prMbox() not dealing with 0 ux/uy
Stuff like this: /MediaBox[780.04 1086.94 0 0] crops up in the wild. When fed the above values, prMbox() will silently use its default ux and uy (which renders the output PDF unuseable, that's why I assigned "critical"): sub prMbox { my $lx = shift || 0; my $ly = shift || 0; my $ux = shift || 595; # doesn't handle 0 my $uy = shift || 842; # doesn't handle 0 Wouldn't this be better written as: sub prMbox { my $lx = defined($_[0]) ? shift : 0; my $ly = defined($_[0]) ? shift : 0; my $ux = defined($_[0]) ? shift : 595; my $uy = defined($_[0]) ? shift : 842; Best regards Thomas