63 lines
1.2 KiB
Text
63 lines
1.2 KiB
Text
$NetBSD: patch-bq,v 1.3 2013/02/26 11:07:26 joerg Exp $
|
||
|
||
* Use standard strdup(3).
|
||
|
||
--- conf/mhconfig.c.orig 2001-05-29 15:04:36.000000000 +0000
|
||
+++ conf/mhconfig.c
|
||
@@ -6,6 +6,8 @@ static char ident[] = "@(#)$Id: mhconfig
|
||
|
||
#include <ctype.h>
|
||
#include <stdio.h>
|
||
+#include <stdlib.h>
|
||
+#include <string.h>
|
||
#ifdef hpux
|
||
#define SYS5
|
||
#endif
|
||
@@ -16,7 +18,6 @@ static char ident[] = "@(#)$Id: mhconfig
|
||
|
||
static void insopt(), mkopts();
|
||
|
||
-extern char *strcpy(), *malloc(), *index(), *rindex();
|
||
#ifdef notdef
|
||
extern char *sprintf(); /* rely on stdio.h to declare this */
|
||
#endif
|
||
@@ -266,9 +267,10 @@ static struct pair {
|
||
|
||
|
||
static do_sed(), do_sedfile(), do_files(), do_doc(), do_make();
|
||
-static shell(), arginit(), add_option(), trim();
|
||
+static shell(), arginit(), add_option();
|
||
+static void trim(char *);
|
||
|
||
-static char *stradd (), *strdup (), *tail ();
|
||
+static char *stradd (), *tail ();
|
||
|
||
/* */
|
||
|
||
@@ -959,8 +961,7 @@ end_myopt () {
|
||
|
||
/* */
|
||
|
||
-static trim (s)
|
||
-char *s;
|
||
+static void trim(char *s)
|
||
{
|
||
char *p;
|
||
|
||
@@ -1002,7 +1003,7 @@ char *s1,
|
||
return p;
|
||
}
|
||
|
||
-
|
||
+#if 0
|
||
static char *strdup (s)
|
||
char *s;
|
||
{
|
||
@@ -1014,6 +1015,7 @@ char *s;
|
||
(void) strcpy (p, s);
|
||
return p;
|
||
}
|
||
+#endif
|
||
|
||
/* */
|
||
|