Re: apmd C getopt flag unused?
On Wed, Aug 07, 2019 at 12:40:03PM +0200, Claudio Jeker wrote: > On Wed, Aug 07, 2019 at 12:33:58PM +0200, Solene Rapenne wrote: > > I found case 'C' in getopt in amd which is not documented and seems to > > be an alias for -A. > > > > Ok for removing? > > Please don't, I think many people still use the old apmd -C (at least I do > have it on a few systems). Also you should remove it from the getopt > string. OK For history, commit message removing -C flag and making it fallback on -A https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.sbin/apmd/apmd.c?rev=1.71=text/x-cvsweb-markup
Re: apmd C getopt flag unused?
On Wed, Aug 07, 2019 at 12:33:58PM +0200, Solene Rapenne wrote: > I found case 'C' in getopt in amd which is not documented and seems to > be an alias for -A. > > Ok for removing? Please don't, I think many people still use the old apmd -C (at least I do have it on a few systems). Also you should remove it from the getopt string. > Index: apmd.c > === > RCS file: /data/cvs/src/usr.sbin/apmd/apmd.c,v > retrieving revision 1.84 > diff -u -p -r1.84 apmd.c > --- apmd.c4 Dec 2018 18:00:57 - 1.84 > +++ apmd.c7 Aug 2019 10:30:49 - > @@ -417,7 +417,6 @@ main(int argc, char *argv[]) > statonly = 1; > break; > case 'A': > - case 'C': > if (doperf != PERF_NONE) > usage(); > doperf = PERF_AUTO; > -- :wq Claudio
Re: apmd C getopt flag unused?
On Wed, Aug 07, 2019 at 12:33:58PM +0200, Solene Rapenne wrote: > I found case 'C' in getopt in amd which is not documented and seems to > be an alias for -A. > > Ok for removing? > > Index: apmd.c > === > RCS file: /data/cvs/src/usr.sbin/apmd/apmd.c,v > retrieving revision 1.84 > diff -u -p -r1.84 apmd.c > --- apmd.c4 Dec 2018 18:00:57 - 1.84 > +++ apmd.c7 Aug 2019 10:30:49 - > @@ -417,7 +417,6 @@ main(int argc, char *argv[]) > statonly = 1; > break; > case 'A': > - case 'C': > if (doperf != PERF_NONE) > usage(); > doperf = PERF_AUTO; > I sent my mail to quick. C is "PERF_COOL" profile but it doesn't seem used anymore because case 'A' and 'C' have PERF_AUTO but there is still a few lines about PERF_COOL. If someone confirms me it's obsolete, I'll do a proper diff for cleaning this.
apmd C getopt flag unused?
I found case 'C' in getopt in amd which is not documented and seems to be an alias for -A. Ok for removing? Index: apmd.c === RCS file: /data/cvs/src/usr.sbin/apmd/apmd.c,v retrieving revision 1.84 diff -u -p -r1.84 apmd.c --- apmd.c 4 Dec 2018 18:00:57 - 1.84 +++ apmd.c 7 Aug 2019 10:30:49 - @@ -417,7 +417,6 @@ main(int argc, char *argv[]) statonly = 1; break; case 'A': - case 'C': if (doperf != PERF_NONE) usage(); doperf = PERF_AUTO;