On Thu, Jun 14, 2018 at 06:28:47AM BST, Nan Xiao wrote:
> Hi tech@,
> 
> The following patch fix some inaccurate comment in w.c. E.g., there is
> no "-n" option, and "-a" instead. Sorry id I am wrong, thanks!
> 
> Index: w.c
> ===================================================================
> RCS file: /cvs/src/usr.bin/w/w.c,v
> retrieving revision 1.65
> diff -u -p -r1.65 w.c
> --- w.c       18 Dec 2017 05:51:53 -0000      1.65
> +++ w.c       14 Jun 2018 05:17:00 -0000
> @@ -71,9 +71,9 @@ struct winsize      ws;
>  kvm_t               *kd;
>  time_t               now;            /* the current time of day */
>  int          ttywidth;       /* width of tty */
> -int          argwidth;       /* width of tty */
> -int          header = 1;     /* true if -h flag: don't print heading */
> -int          nflag = 1;      /* true if -n flag: don't convert addrs */
> +int          argwidth;       /* width of name and args of the current 
> process */
> +int          header = 1;     /* false if -h or -M flag: don't print heading 
> */
> +int          nflag = 1;      /* false if -a flag: don't convert addrs */
>  int          sortidle;       /* sort by idle time */
>  char        *sel_user;       /* login of particular user selected */
>  char         domain[HOST_NAME_MAX+1];

FYI, the '-n' to '-a' change happened nearly 22 years ago[0].

Given that "-a flag" should clearly be in the comment, shouldn't
there a mechanical nflag -> aflag change also take place?

[0] 
http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/w/w.c.diff?r1=1.5&r2=1.6&f=h

Regards,

Raf

Reply via email to