Re: socklen_t

2005-09-01 Thread Albert Chin
On Thu, Sep 01, 2005 at 01:28:39PM +0200, Simon Josefsson wrote: > Albert Chin <[EMAIL PROTECTED]> writes: > > > We created the following macro for curl. It's been tested on the > > following systems: > > Has the copyright been assigned to the FSF? No. I'd like to see a liberal license with this

lib/glob.c change to rename LOGIN_NAME_MAX

2005-09-01 Thread Paul Eggert
I installed this, imported from a proposed patch in the glibc database: 2005-09-01 Paul Eggert <[EMAIL PROTECTED]> * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX, to avoid a collision with bits/local_lim.h in glibc. All uses changed. Problem reported by

Re: [bug-gnulib] inttostr module: missing m4 files

2005-09-01 Thread Bruno Haible
Martin Lambers wrote: > I think the inttostr module needs to include three additional m4 files > to define the following macros: > gl_AC_HEADER_STDINT_H (needed by intmax_t.m4, uintmax_t.m4), > gl_AC_HEADER_INTTYPES_H (needed by uintmax_t.m4), and > gl_AC_TYPE_UNSIGNED_LONG_LONG (needed by uintmax_

regex portability glitches with size_t versus int

2005-09-01 Thread Paul Eggert
I installed this and file glibc bug 1286: 2005-09-01 Paul Eggert <[EMAIL PROTECTED]> * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability bugs in int versus size_t comparisons. * config/srclist.txt: Add glibc bug 1285, 1286. --- lib/regex_internal.c1

regex fixes for bool-related issues

2005-09-01 Thread Paul Eggert
I converted the regex code to use bool where it's easy, and found and fixed a few bugs discovered in the process. I installed this and filed glibc bug 1285. 2005-09-01 Paul Eggert <[EMAIL PROTECTED]> Use bool where appropriate. * lib/regcomp.c (re_set_fastmap): ICASE arg is boo

Re: socklen_t

2005-09-01 Thread Simon Josefsson
Bruno Haible <[EMAIL PROTECTED]> writes: > Simon Josefsson wrote: >> A bit weird approach of checking for a compatible type, perhaps, but >> if it works, then I'm all for it. Bruno, what do you think? > > It's the standard way of determining a function's prototype. At first sight, > it would be p

Re: [bug-gnulib] Re: socklen_t

2005-09-01 Thread Bruno Haible
Simon Josefsson wrote: > A bit weird approach of checking for a compatible type, perhaps, but > if it works, then I'm all for it. Bruno, what do you think? It's the standard way of determining a function's prototype. At first sight, it would be possible to use a single loop instead of a double lo

inttostr module: missing m4 files

2005-09-01 Thread Martin Lambers
Hi! I think the inttostr module needs to include three additional m4 files to define the following macros: gl_AC_HEADER_STDINT_H (needed by intmax_t.m4, uintmax_t.m4), gl_AC_HEADER_INTTYPES_H (needed by uintmax_t.m4), and gl_AC_TYPE_UNSIGNED_LONG_LONG (needed by uintmax_t.m4). Regards, Martin -

Re: gnulib-tool changes

2005-09-01 Thread Simon Josefsson
Bruno Haible <[EMAIL PROTECTED]> writes: > Fixed now. ... > Yes. Fixed now as well. ... >> What are these *.tmp files? > > The contain the contents of the file to install. Forgot to remove them. > Now also fixed. Thanks! >> lgl/Makefile.am:18: required file `lgl/memmove.c' not found >> lgl/Makef

Re: gnulib-tool changes

2005-09-01 Thread Bruno Haible
Simon Josefsson wrote: > I'll use GnuTLS as the test subject for this. First impressions: > > [EMAIL PROTECTED]:~/src/gnutls$ gnulib-tool --import > gnulib-tool: *** missing --source-base option > gnulib-tool: *** Stop. > [EMAIL PROTECTED]:~/src/gnutls$ > > That used to work Fixed now. > Then I

Re: socklen_t

2005-09-01 Thread Simon Josefsson
Albert Chin <[EMAIL PROTECTED]> writes: > We created the following macro for curl. It's been tested on the > following systems: Has the copyright been assigned to the FSF? > dnl Check for socklen_t: historically on BSD it is an int, and in > dnl POSIX 1g it is a type of its own, but some platfor

Re: gnulib-tool changes

2005-09-01 Thread Simon Josefsson
Bruno Haible <[EMAIL PROTECTED]> writes: > Simon Josefsson wrote: >> Yup, I'm using two configure.ac's in gsasl, but I don't want to change >> gnutls to use the same scheme for only this reason. And with your >> work, I don't have to. > > OK, can you try it? The essential changes are already in C

Re: socklen_t

2005-09-01 Thread Simon Josefsson
Bruno Haible <[EMAIL PROTECTED]> writes: >> There is a problem, of course, if it _is_ defined in netdb.h and the >> application include that header file, but the test does not look >> there. Then there will be a type conflict. > > We need to somehow avoid the type conflict in that case. The goal

Re: gnulib-tool changes

2005-09-01 Thread Simon Josefsson
Bruno Haible <[EMAIL PROTECTED]> writes: > Simon Josefsson wrote: >> Yup, I'm using two configure.ac's in gsasl, but I don't want to change >> gnutls to use the same scheme for only this reason. And with your >> work, I don't have to. > > OK, can you try it? The essential changes are already in C

Re: [bug-gnulib] Re: socklen_t

2005-09-01 Thread Bruno Haible
Albert Chin wrote: > We created the following macro for curl. It's been tested on the > following systems: > AIX 4.3.3, 5.1, 5.2, 5.3 > HP-UX 10.20, 11.00, 11i > IRIX 6.5 > Redhat Linux 7.1, 9 > RHEL 2.1, 3, 4 > Solaris 2.5.1, 2.6, 7, 8, 9, 10/SPARC > Tru64 UNIX 4.0D, 5.1 > ... >

Re: getdelim doesn't set errno on failure?

2005-09-01 Thread Simon Josefsson
Derek Price <[EMAIL PROTECTED]> writes: > Whoa! Why fix the documentation? Why not simply return EOF on EOF, as > currently described? The attached simple patch fixes this in > lib/getdelim.c, matching the behavior to that displayed by my local > glibc. This fix has been tested on at least one

Re: gnulib-tool changes

2005-09-01 Thread Bruno Haible
Simon Josefsson wrote: > Yup, I'm using two configure.ac's in gsasl, but I don't want to change > gnutls to use the same scheme for only this reason. And with your > work, I don't have to. OK, can you try it? The essential changes are already in CVS. > >> How about storing the parameters in the

Re: socklen_t

2005-09-01 Thread Bruno Haible
Simon Josefsson wrote: > POSIX says both sys/socket.h and netdb.h should declare > socklen_t, I was thinking of the case where a system doesn't have > sys/socket.h but has netdb.h. Yes, this is the case that can cause trouble. Some very old systems fall in this category. > Do you think we should

wctype.h and wchar.h inclusion

2005-09-01 Thread Yoann Vandoorselaere
Hi, An OpenBSD Prelude user reported that GnuLib will fail to compile on OpenBSD 3.7 due to the new dependencies of modules like strcase on wctype.h and wchar.h headers. These headers are apparently not available on OpenBSD base system. libutf8 provide these header, but they get installed in an

Re: gnulib-tool changes

2005-09-01 Thread Simon Josefsson
Bruno Haible <[EMAIL PROTECTED]> writes: > Simon Josefsson wrote: >> Yay! I considered dropping use of gnulib in libgnutls yesterday, >> because I wanted the error module for the tools, but that module need >> a program_name variable. When the library didn't provide one, there >> were linker fai

Re: socklen_t

2005-09-01 Thread Simon Josefsson
Bruno Haible <[EMAIL PROTECTED]> writes: > Normally and should be sufficient to get > socklen_t. Which are the systems where it needs ? I don't know; POSIX says both sys/socket.h and netdb.h should declare socklen_t, I was thinking of the case where a system doesn't have sys/socket.h but has ne

Re: const-correctness fixes for regex

2005-09-01 Thread Jim Meyering
Paul Eggert <[EMAIL PROTECTED]> wrote: > Jim Meyering <[EMAIL PROTECTED]> writes: >> A week or so ago, I stumbled across one interface that was missing a >> `const' attribute on a parameter, then dug up a few more. Paul, let me >> know when you reach a point at which my checking this in won't inte

Re: socklen_t

2005-09-01 Thread Albert Chin
On Wed, Aug 31, 2005 at 04:18:20PM +0200, Simon Josefsson wrote: > +AC_DEFUN([gl_SOCKLEN_T], > +[ > + AC_CHECK_HEADERS_ONCE(sys/types.h sys/socket.h netdb.h) > + AC_CHECK_TYPE([socklen_t],, [AC_DEFINE([socklen_t], [int], > +[Map `socklen_t' to `int' if it is missing.])], [ > +#ifd

Re: warning: comparison is always false due to limited range of data type

2005-09-01 Thread Jim Meyering
Paul Eggert <[EMAIL PROTECTED]> wrote: > Jim Meyering <[EMAIL PROTECTED]> writes: >> Is it really permitted to have sizeof (size_t) < sizeof (unsigned int)? ... >> The offending warning breaks coreutils' `make distcheck' rule. > > Would it make sense to rewrite coreutils 'make distcheck' to filter

improved regex sanity checks for large buffer sizes

2005-09-01 Thread Paul Eggert
I installed this and filed glibc bug 1284: 2005-08-31 Paul Eggert <[EMAIL PROTECTED]> * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer lengths fit in regoff_t; this isn't true if regoff_t is the same width as size_t. * lib/regex.c (re_search_in