2003-06-14 H.J. Lu <hongjiu.lu@intel.com>
[deliverable/binutils-gdb.git] / readline / savestring.c
index 485890ea57cd6e524412a4b0a8f01d8aba5d5bfb..c7ebeb1e55275e282da885fd43cf33d75c9028ac 100644 (file)
    have a copy of the license, write to the Free Software Foundation,
    59 Temple Place, Suite 330, Boston, MA 02111 USA. */
 
-extern char *strcpy ();
-extern char *xmalloc ();
+#include <config.h>
+#ifdef HAVE_STRING_H
+#  include <string.h>
+#endif
+#include "xmalloc.h"
 
 /* Backwards compatibility, now that savestring has been removed from
    all `public' readline header files. */
 char *
 savestring (s)
-     char *s;
+     const char *s;
 {
-  return ((char *)strcpy (xmalloc (1 + (int)strlen (s)), (s)));
+  return ((char *)strcpy ((char *)xmalloc (1 + strlen (s)), (s)));
 }
This page took 0.036002 seconds and 4 git commands to generate.