Re: [PATCH] usage_with_options: omit double new line on empty option list

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

 



Stefan Beller <sbeller@xxxxxxxxxx> writes:

> Upon closer inspection, I have the impression that f389c808b6
> (Rework make_usage to print the usage message immediately,
> 2007-10-14) introduced the extra new line without giving a rationale.

I do not think that is the case.  The code before that patch
collected all the usage strings in a strbuf sb, which had lines with
their own terminating LFs, and then called usage() on sb.buf, which
added an extra LF, so I think the commit was a faithful and bug-to-bug
compatible rewrite.

But that does not matter in the bigger picture, as long as everybody
agrees with the following:

>> The other fputc('\n', outfile) that this version of the patch
>> touches is what I had trouble with, and I still do.  There must be a
>> similar rationale like the previous one, i.e. "We have finished
>> giving the usage, and we have finished showing all the options.  Now
>> we are about to further show X, so let's have a blank line here so
>> that what we have wrote will be separated from it", but I cannot
>> tell what that X is.
>
> Oh. I assumed that this X is the the next command in the users
> terminal, but I checked other commands and that is not the case
> at all (at least ls, vi, tar)

Thanks.



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux