[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp
From: |
Ulrich Drepper |
Subject: |
[Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes |
Date: |
Sun, 07 Mar 2004 23:07:22 -0800 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7b) Gecko/20040307 |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Marcus Brinkmann wrote:
> I got a hint that the internal interfaces in posix/getopt.h are not
> desired.
Don't move the declarations into include/getopt.h. Instead create a new
internal header, getopt_int.h or whatever named. Move all the internal
stuff in there. This means users outside glibc will have to copy along
another file but that cannot be a problem.
The patch itself is botch. What is
- --- libc-old/posix/Versions 2004-03-06 21:10:17.000000000 +0100
+++ libc/posix/Versions 2004-03-08 02:47:28.000000000 +0100
@@ -125,7 +125,5 @@ libc {
__libc_wait; __libc_waitpid; __libc_pause; __libc_nanosleep;
__libc_fork;
__libc_pread; __libc_pread64; __libc_pwrite; __libc_pwrite64;
__waitid; __pselect;
- - # used by argp
- - __getopt_long_r; __getopt_long_only_r;
}
supposed to mean? There never were such entries.
There should be no need for the global __getopt_initialized variable.
Just always use the value in the struct. This variable has always been
internal. Also, in _getopt_internal() there should be no need to copy
the variables going into the function. Check the code all paths whether
any of the values is being read. I might miss something but I think
there are none. I do not worry about the case where the value in the
global opt* variables gets overwritten with a value from __getopt_data
even though the latter hasn't been written to in the _getopt_internal_r
call.
Aslo, you're using some C99 syntax which probably won't make the gnulib
people happy. Look for uses of _GETOPT_DATA_INITIALIZER.
- --
➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)
iD8DBQFATBuu2ijCOnn/RHQRArbBAKDDWTG18FZ/5KyNcZjHWkuwOvrHPwCeO8el
FDXw2G3DNT1cU/0oVHmzQAo=
=n5nf
-----END PGP SIGNATURE-----
- [Bug-gnulib] [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Marcus Brinkmann, 2004/03/06
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Ulrich Drepper, 2004/03/06
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Roland McGrath, 2004/03/06
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Ulrich Drepper, 2004/03/06
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Roland McGrath, 2004/03/06
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Marcus Brinkmann, 2004/03/10
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Marcus Brinkmann, 2004/03/10
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Marcus Brinkmann, 2004/03/10
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Roland McGrath, 2004/03/10
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes,
Ulrich Drepper <=
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Marcus Brinkmann, 2004/03/10
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Paul Eggert, 2004/03/10
- [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, Ulrich Drepper, 2004/03/10
Re: [Bug-gnulib] Re: [PATCH] getopt, argp - reentrant getopt interface, argp fixes, James Youngman, 2004/03/10