On Wed, Jan 05, 2005 at 11:04:34AM -0800, Richard Morin wrote:
> close $fh || warn "@_ didn't run correctly";
>
> print STDERR "run_program was here!\n"; # DEBUG
>
> # When using IPC::Open3, need to reap the processes.
>
> waitpid $self->{pid}, 0 if delete $self->{pid};
>
> return $output;
> }
>
> Sadly, I am not yet seeing any of the warning messages:
>
> ...
> run_program was here!
> Error (0): PDF file is damaged - attempting to
> reconstruct xref table...
> run_program was here!
> Error (0): PDF file is damaged - attempting to
> reconstruct xref table...
> run_program was here!
> ...
>
> Help? Clues? Suggestions?
Ah, maybe warn is being trapped. What if you change that "warn" to
"print STDERR".
On the other hand maybe it's not returning an error code. Try first
from the command line. So if your problem pdf is called "bad.pdf" you
can try with:
pdfinfo bad.pdf || echo "It's bad"
I assume pdfinfo or pdftotext is returning an error code.
You might also add to your "run_program was here!" message $self->name
and @_ to see more what's happening:
print STDERR "run_program: params are [@_] and document is " . $self->name;
--
Bill Moseley
moseley@hank.org
Unsubscribe from or help with the swish-e list:
http://swish-e.org/Discussion/
Help with Swish-e:
http://swish-e.org/current/docs
swish-e@sunsite.berkeley.edu
Received on Wed Jan 5 11:22:54 2005