Le Thu, Apr 23, 2015 at 08:00:08PM +0200, martin f krafft a écrit :
> 
> % pdfmod
> zsh: command not found: pdfmod
> 
> % run-mailcap --debug --action=edit /tmp/3290_001.pdf
(...)
>  - running test: test -n "$DISPLAY"  (result=0=true)
>  - executing: pdfmod /tmp/3290_001.pdf
> 
> % echo $?
> 0

Thanks Martin for the report.

Here are the Perl commands defining the returned error code.

----------------------------------------------
        print STDERR " - executing: $comm\n" if $debug;
        if ($norun) {
            print $comm,"\n";
            $res = 0;
        } else {
            $res = system $comm;
            $res = int($res/256);
        }
        if ($res != 0) {
            print STDERR "Warning: program returned non-zero exit code 
\#$res\n";
            $retcode = $res;
        }
(...)
exit($retcode);
----------------------------------------------

I do not understand why the original command's error code (127 in our case) is
turned to zero by changing it to "int($res/256)".  I could remove this, but
before doing so, I would prefer to understand why it is done like this.  Do you
have an idea ?  If not, I will ask to the original author.

Have a nice day,

-- 
Charles Plessy
Tsurumi, Kanagawa, Japan


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to