Skip Menu |

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

Report information
The Basics
Id: 48032
Status: open
Priority: 0/
Queue: PDF-FromHTML

People
Owner: Nobody in particular
Requestors: jpierce [...] cpan.org
Cc:
AdminCc:

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



Subject: Contrary to to dox, html2pdf.pl does not process STDIN
echo "<html><head><title>Foo</title></head><body>Bar</body></html" | html2pdf.pl | less Begets: No such file or directory at /usr/lib/perl5/site_perl/5.8.5/PDF/FromHTML.pm line 106. at /usr/bin/html2pdf.pl line 52 main::__ANON__('No such file or directory at /usr/lib/perl5/site_perl/5.8.5/P...') called at /usr/lib/perl5/site_perl/5.8.5/PDF/FromHTML.pm line 106 PDF::FromHTML::parse_file('PDF::FromHTML=HASH(0x9bf805c)') called at /usr/lib/perl5/site_perl/5.8.5/PDF/FromHTML.pm line 171 PDF::FromHTML::convert('PDF::FromHTML=HASH(0x9bf805c)', 'Font', 'Helvetica', 'LineHeight', 12, 'Landscape', 0) called at /usr/bin/html2pdf.pl line 58 This seems to be an issue with 3-arg open, the 2-arg form works fine. Checking 5.10 docs, there seems to be no 3-arg equivalent of the - shorthand for STD*... --- /usr/lib/perl5/site_perl/5.8.5/PDF/FromHTML.pm 2009-07-20 17:24:48.000000000 -0400 +++ /usr/lib/perl5/site_perl/5.8.5/PDF/FromHTML.pm~ 2008-12-16 07:38:57.000000000 -0500 @@ -103,7 +103,7 @@ my $dir = Cwd::getcwd(); if (!ref $file) { - open my $fh, "<$file" or die $!; + open my $fh, '<', $file or die $!; chdir File::Basename::dirname($file); $content = do { local $/; <$fh> }; }
Note, patch is reversed.