Re: optind and friends are already declared

2017-11-06 Thread Jan Stary
If there is any interest in this at all, there's a similar diff for usr.bin/ and usr.sbin/ Jan > On Nov 03 18:34:11, h...@stare.cz wrote: > > Including when using getopt(3) also makes > > extern int opterr, optind, optopt, optreset; > > and friends declared, but many utils redeclare

Re: optind and friends are already declared

2017-11-03 Thread Jan Stary
> On Nov 03 18:34:11, h...@stare.cz wrote: > > Including when using getopt(3) also makes > > extern int opterr, optind, optopt, optreset; > > and friends declared, but many utils redeclare them again. Here is a diff for regress/ Jan Index: lib/libc/db/dbtest.c

Re: optind and friends are already declared

2017-11-03 Thread Jan Stary
> On Nov 03 18:34:11, h...@stare.cz wrote: > > Including when using getopt(3) also makes > > extern int opterr, optind, optopt, optreset; > > and friends declared, but many utils redeclare them again. > > > > Is there a reason for that, or can those be removed? > > As a harmless example, here's

Re: optind and friends are already declared

2017-11-03 Thread Jan Stary
(Sorry for the missing Subject.) On Nov 03 18:34:11, h...@stare.cz wrote: > Including when using getopt(3) also makes > extern int opterr, optind, optopt, optreset; > and friends declared, but many utils redeclare them again. > > Is there a reason for that, or can those be removed? > As a