Subject: readline-2.1
To: None <bug-readline@prep.ai.mit.edu>
From: Gordon W. Ross <gwr@mc.com>
List: tech-toolchain
Date: 09/25/1997 21:46:30
Readline defines a function named savestring() for backward-
compatibility with the old readline.  However, the old version
of readline had the following define in chardefs.h:

	#ifndef savestring
	#define savestring(X) _rl_savestring(X)
	extern char * _rl_savestring ();
	#endif

Therefore, the correct name for a backward-compatibility
function would be _rl_savestring.  Also, if this change
is not made, then gdb-4.16 has a conflicting definition
of this function.  Here is the change I suggest:

(Context diff against readline-2.1)
diff -c -r1.1 -r1.2
*** shell.c     1997/09/24 16:49:18     1.1
--- shell.c     1997/09/26 01:37:51     1.2
***************
*** 45,53 ****
  #endif
  
  /* Backwards compatibility, now that savestring has been removed from
!    all `public' readline header files. */
  char *
! savestring (s)
       char *s;
  {
    return ((char *)strcpy (xmalloc (1 + (int)strlen (s)), (s)));
--- 45,54 ----
  #endif
  
  /* Backwards compatibility, now that savestring has been removed from
!    all `public' readline header files.  Note that the actual name of
!    this function in the old library was _rl_savestring.  */
  char *
! _rl_savestring (s)
       char *s;
  {
    return ((char *)strcpy (xmalloc (1 + (int)strlen (s)), (s)));