Re: new module 'freadseek'

2008-03-01 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Eric Blake on 3/1/2008 1:36 PM: | On further investigation, I think this is a true bug in newlib's stdio, | and not in your code. Newlib has two bugs - first, fflush is failing to discard ungetc data when changing the underlying fd offse

Re: new module 'freadseek'

2008-03-01 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Eric Blake on 3/1/2008 10:44 AM: | | Somehow, the tweaks you did to the raw _fp to account for the 1-byte | readahead buffer from the arbitrary ungetc trip up the subsequent fseek. | I'm in the process of compiling a debug version of cygw

Re: new module 'freadseek'

2008-03-01 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Bruno Haible on 2/29/2008 2:29 AM: | Here's the side-effecting companion of freadptr. | /* Increment the in-memory pointer. This is very cheap (no system calls). */ | buffered = freadahead (fp); | if (buffered > 0) | { |

Re: new module memchr2

2008-03-01 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Bruce Korb on 3/1/2008 7:57 AM: |> + charmask1 |= charmask2 << 16; | | Have you tested this? :( Yes, but unfortunately, my tests didn't trigger every possible alignment. ~ Also, the tests made use of the GNU extension of adding int +

Re: [PATCH] bootstrap: sync from coreutils

2008-03-01 Thread Jim Meyering
Jim Meyering <[EMAIL PROTECTED]> wrote: > FYI, I've just pushed this: I've just pushed the ChangeLog entry, too.

[PATCH] bootstrap: sync from coreutils

2008-03-01 Thread Jim Meyering
FYI, I've just pushed this: bootstrap: sync from coreutils * build-aux/bootstrap (update_po_files): Copy a .po file into place also when the target doesn't exist. diff --git a/build-aux/bootstrap b/build-aux/bootstrap index 87a2798..d68d3f4 100755 --- a/build-aux/bootstrap

Re: [PATCH] Remove useless "if" tests before free. Deprecate "free" module.

2008-03-01 Thread Jim Meyering
Bruno Haible <[EMAIL PROTECTED]> wrote: > Jim Meyering wrote: >> --- a/modules/free >> +++ b/modules/free >> @@ -1,5 +1,9 @@ >> Description: >> Work around incompatibility on older systems where free (NULL) fails. >> +# Note: as of 2008, this module is no longer useful, since no >> +# "reasonable

[PATCH] (getdelim): Don't leak memory upon failed realloc.

2008-03-01 Thread Jim Meyering
Hi Simon, I noticed that our getdelim replacement can leak when the initial realloc fails. While that can happen only when *N is 0 and *LINEPTR is malloc'd, I think it's worth fixing, if only to avoid further discussion on the topic. Here's the fix. Ok to apply? * lib/getdelim.c (getde

new module memchr2

2008-03-01 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 M4 has a situation where it wants to search for the first of two candidate bytes within an arbitrary string. In fact, Bruno profiled m4 when running autoconf on the gettext package, and found that more than 10% of the total execution time was in a ho

Re: [PATCH] Remove useless "if" tests before free. Deprecate "free" module.

2008-03-01 Thread Bruno Haible
Jim Meyering wrote: > --- a/modules/free > +++ b/modules/free > @@ -1,5 +1,9 @@ > Description: > Work around incompatibility on older systems where free (NULL) fails. > +# Note: as of 2008, this module is no longer useful, since no > +# "reasonable portability target" (which excludes SunOS4) syst

[PATCH] Remove useless "if" tests before free. Deprecate "free" module.

2008-03-01 Thread Jim Meyering
Here's a proposed patch to remove all redundant "if"-before-free tests in the tests/ directory and in the lib/*.c files not owned by Bruno. It also deprecates (in comments and documentation) the free module. Paul ok'd that part. Simon, this affects two files that are yours: lib/gc-gnulib.c and l