Re: [PATCH] readline: fix memory leak in replacement readline.

2023-05-30 Thread Paul Eggert
Thanks, I installed that.

[PATCH] readline: fix memory leak in replacement readline.

2023-05-30 Thread Nick Bowler
The getline function allocates memory that has to be freed by the caller regardless of whether or not the call succeeds. This is the case at least on current GNU libc getline, and also the case with Gnulib's own replacement getline implementation. Gnulib's readline replacement, which calls getlin

Re: readline fix

2005-11-10 Thread Eric Blake
> > Some testing reveal that the readline strip any number of \n or \r at > the end: > > [EMAIL PROTECTED]:~$ cat foo.c > #include > > int main () { > char *foo = readline("bar: "); > size_t i; > > for (i = 0; i < strlen (foo); i++) > printf ("%02x\n", foo[i]); > } Your test app was

Re: readline fix

2005-11-10 Thread Simon Josefsson
Eric Blake <[EMAIL PROTECTED]> writes: > According to Simon Josefsson on 11/9/2005 7:17 PM: >> Is this right? I'm not sure what a portable way to remove EOL is. >> Anyway, I installed this because it work on known platforms. > > The concept is correct (the full-blown readline library does indeed

Re: readline fix

2005-11-09 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Simon Josefsson on 11/9/2005 7:17 PM: > Is this right? I'm not sure what a portable way to remove EOL is. > Anyway, I installed this because it work on known platforms. The concept is correct (the full-blown readline library does indeed

readline fix

2005-11-09 Thread Simon Josefsson
Is this right? I'm not sure what a portable way to remove EOL is. Anyway, I installed this because it work on known platforms. 2005-11-10 Simon Josefsson <[EMAIL PROTECTED]> * readline.c: Remove EOL. --- readline.c 20 Sep 2005 11:12:16 +0200 1.2 +++ readline.c 10 Nov 2005 03