bug-coreutils
[Top][All Lists]
Advanced

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

bug#18531: [PATCH] man: Fix an inverted test that prevented dummy-man fr


From: Bernhard Voelker
Subject: bug#18531: [PATCH] man: Fix an inverted test that prevented dummy-man from working
Date: Mon, 22 Sep 2014 23:42:34 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.1.0

On 09/22/2014 10:11 PM, Andreas Schwab wrote:
> Pádraig Brady <address@hidden> writes:
> 
>> On 09/22/2014 10:53 AM, Alban Bedel wrote:
>>> diff --git a/man/dummy-man b/man/dummy-man
>>> index bf31912..65b85d5 100755
>>> --- a/man/dummy-man
>>> +++ b/man/dummy-man
>>> @@ -39,7 +39,7 @@ while test $# -gt 0; do
>>>  done
>>>  
>>>  test $# -gt 0 || fatal_ "missing argument"
>>> -test $# -le 1 || fatal_ "too many non-option arguments"
>>> +test $# -gt 1 || fatal_ "too many non-option arguments"
>>>  
>>>  baseout=`basename_ "$output"`
>>>  sed 's/^/WARNING: /' >&2 <<END
>>
>> Nice one.
> 
> Huh?
> 
> $ man/dummy-man foo
> man/dummy-man: too many non-option arguments
> 
> Andreas.
> 

oops, in commit b3578fc9ffe70b9466687f9f6470a85f1a0ab14f
I added the --info-page=... option _after_ the program argument
in local.mk.  The original help2man doesn't have a problem with
that, as it does the normal GNU option parsing, but the parsing
loop in dummy-man stops parsing when it hit the program argument,
thus leaving $# = 2 (and the --info-page option unused).

I'll propose a fix for both the test in dummy-man and local.mk
soon.

Have a nice day,
Berny





reply via email to

[Prev in Thread] Current Thread [Next in Thread]