aboutsummaryrefslogtreecommitdiff
path: root/contrib/gdb
diff options
context:
space:
mode:
authorDavid E. O'Brien <obrien@FreeBSD.org>2002-07-09 17:01:47 +0000
committerDavid E. O'Brien <obrien@FreeBSD.org>2002-07-09 17:01:47 +0000
commita841c6d1fadfe6df8463b6ceb43aa479bfa237db (patch)
treed16fc1b0a4da086742254cad6b7044210547ad15 /contrib/gdb
parent455a6759e8aaa28dcafa8497a852448cb88c9413 (diff)
downloadsrc-a841c6d1fadfe6df8463b6ceb43aa479bfa237db.tar.gz
src-a841c6d1fadfe6df8463b6ceb43aa479bfa237db.zip
Quiet warnings by making this ANSI-C clean.
Notes
Notes: svn path=/head/; revision=99675
Diffstat (limited to 'contrib/gdb')
-rw-r--r--contrib/gdb/gdb/gdbserver/gdbreplay.c23
1 files changed, 18 insertions, 5 deletions
diff --git a/contrib/gdb/gdb/gdbserver/gdbreplay.c b/contrib/gdb/gdb/gdbserver/gdbreplay.c
index dce4079e3f18..e13f625a691d 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 <stdio.h>
#include <sys/file.h>
@@ -30,6 +32,15 @@
#include <ctype.h>
#include <fcntl.h>
#include <errno.h>
+#ifdef HAVE_STDLIB_H
+#include <stdlib.h>
+#endif
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+#ifdef HAVE_STRING_H
+#include <string.h>
+#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;