getopt bugs
Corinna Vinschen
corinna-cygwin@cygwin.com
Tue Dec 1 14:48:00 GMT 2009
On Dec 1 06:53, Eric Blake wrote:
> According to Corinna Vinschen on 12/1/2009 2:42 AM:
> > I tend to the first choice with a rather strong option to the third.
> >
> > A patch for the first choice might look like this (untested):
> >
> > * libc/getopt.c (getopt_internal): Reevaluate POSIXLY_CORRECT
> > if optind is set to 0. Handle a leading '-' in options independently
> > of posixly_correct.
>
> Looks decent to me, although you might also want to let optreset!=0 cause
> a reread (since later on, optind==0 is translated to optreset=1).
Good idea.
Corinna
--
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Project Co-Leader cygwin AT cygwin DOT com
Red Hat
More information about the Cygwin-developers
mailing list