Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Mark Kettenis <mark.kettenis@xs4all.nl>
To: qqxnjvamvxwx@spammotel.com
Cc: gdb-patches@sources.redhat.com, bash-maintainers@gnu.org
Subject: Re: Patch to prevent tilde crashing readline
Date: Sun, 03 Jul 2005 08:23:00 -0000	[thread overview]
Message-ID: <200507030823.j638Nbjq010621@elgar.sibelius.xs4all.nl> (raw)
In-Reply-To: <20050702224856.037DC1D14D@cpc4-cmbg1-6-0-cust148.cmbg.cable.ntl.com> (message from Martin Simmons on Sat, 2 Jul 2005 23:48:56 +0100 (BST))

   From: Martin Simmons <qqxnjvamvxwx@spammotel.com>
   Date: Sat,  2 Jul 2005 23:48:56 +0100 (BST)

   Here is a patch to the gdb readline to fix a typo in the MinGW changes.  The
   current CVS gdb segfaults on x86_64 FC3 Linux whenever ~ is used, e.g.

   source ~martin/my-commands

   The segfault is in strlen(), called from tilde_expand(), because
   tilde_expand_word() returns NULL when HAVE_GETPWNAM is not defined
   (i.e. always!).  Someone should fix tilde_expand_word() to do the existing
   else clause in this case.

Oops, Thanks Martin!  I committed the attached patch (since it is
obviously correct).

Chet, I'm not sure whether you incorporated Mark Mitschell's MinGW
changes yet, but you'll at least want to apply this change.

Mark


Index: ChangeLog.gdb
from  Mark Kettenis <kettenis@gnu.org>

	From Martin Simmons:
	* configure.in: Check for getpwnam instead of getpwname.
	* configure: Regenerate.

Index: configure.in
===================================================================
RCS file: /cvs/src/src/readline/configure.in,v
retrieving revision 1.7
diff -u -p -r1.7 configure.in
--- configure.in 9 May 2005 19:42:03 -0000 1.7
+++ configure.in 3 Jul 2005 08:18:03 -0000
@@ -120,7 +120,7 @@ AC_HEADER_DIRENT
 
 AC_CHECK_FUNCS(fcntl kill lstat memmove putenv select setenv setlocale \
 	       strcasecmp strpbrk tcgetattr vsnprintf isascii isxdigit \
-               getpwname getpwent getpwuid)
+               getpwnam getpwent getpwuid)
 
 AC_FUNC_STRCOLL
 


      reply	other threads:[~2005-07-03  8:23 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-02 22:49 Martin Simmons
2005-07-03  8:23 ` Mark Kettenis [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200507030823.j638Nbjq010621@elgar.sibelius.xs4all.nl \
    --to=mark.kettenis@xs4all.nl \
    --cc=bash-maintainers@gnu.org \
    --cc=gdb-patches@sources.redhat.com \
    --cc=qqxnjvamvxwx@spammotel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox