From bca882d5e9b0b84a954260ab62edd02e29271b16 Mon Sep 17 00:00:00 2001 From: obrien Date: Tue, 9 Jul 2002 17:01:47 +0000 Subject: Quiet warnings by making this ANSI-C clean. --- contrib/gdb/gdb/gdbserver/gdbreplay.c | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) (limited to 'contrib/gdb') diff --git a/contrib/gdb/gdb/gdbserver/gdbreplay.c b/contrib/gdb/gdb/gdbserver/gdbreplay.c index dce4079..e13f625 100644 --- a/contrib/gdb/gdb/gdbserver/gdbreplay.c +++ b/contrib/gdb/gdb/gdbserver/gdbreplay.c @@ -19,6 +19,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ +/* $FreeBSD$ */ + #include "config.h" #include #include @@ -30,6 +32,15 @@ #include #include #include +#ifdef HAVE_STDLIB_H +#include +#endif +#ifdef HAVE_UNISTD_H +#include +#endif +#ifdef HAVE_STRING_H +#include +#endif /* Sort of a hack... */ #define EOL (EOF - 1) @@ -40,7 +51,7 @@ static int remote_desc; as the file name for which the error was encountered. Then return to command level. */ -void +static void perror_with_name (char *string) { #ifndef STDC_HEADERS @@ -71,7 +82,7 @@ sync_error (FILE *fp, char *desc, int expect, int got) exit (1); } -void +static void remote_close (void) { close (remote_desc); @@ -80,10 +91,12 @@ remote_close (void) /* Open a connection to a remote debugger. NAME is the filename used for communication. */ -void +static void remote_open (char *name) { +#ifndef HAVE_STRING_H extern char *strchr (); +#endif if (!strchr (name, ':')) { @@ -230,7 +243,7 @@ logchar (FILE *fp) /* Accept input from gdb and match with chars from fp (after skipping one blank) up until a \n is read from fp (which is not matched) */ -void +static void expect (FILE *fp) { int fromlog; @@ -261,7 +274,7 @@ expect (FILE *fp) /* Play data back to gdb from fp (after skipping leading blank) up until a \n is read from fp (which is discarded and not sent to gdb). */ -void +static void play (FILE *fp) { int fromlog; -- cgit v1.1