[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#536397: lintian: False positive with command-with-path-in-maintainer-script



Stefan Fritsch <sf@sfritsch.de> writes:

> Lintian complains 
>
> apache2.2-common: command-with-path-in-maintainer-script postinst:13
> /usr/sbin/apache2
>
> but /usr/sbin/apache2 is not actually called. The relevant line is:
>
> chmod `dpkg-statoverride --list /usr/sbin/apache2 | cut -f 3` /usr/sbin/apache2

This is a bug in $LEADIN that causes it to catch things immediately
after the *closing* backtick in a backtick expression.  This will also
affect checkbashisms in devscripts.

I think the fix is to change:

    our $LEADIN = qr'(?:(?:^|[`&;(|{])\s*|(?:if|then|do|while)\s+)';

to:

    our $LEADIN = qr'(?:(?:^|[&;(|{]|^[^`]*`)\s*|(?:if|then|do|while)\s+)';

but I'm not sure and could use more review.

-- 
Russ Allbery (rra@debian.org)               <http://www.eyrie.org/~eagle/>



Reply to: