This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH 6/6] Remove fatal function and prototype


This commit removes the now-unused fatal function and prototype.

gdb/gdbserver/
2014-08-06  Gary Benson  <gbenson@redhat.com>

	* utils.h (fatal): Remove declaration.
	* utils.c (fatal): Remove function.
---
 gdb/gdbserver/ChangeLog |    5 +++++
 gdb/gdbserver/utils.c   |   17 -----------------
 gdb/gdbserver/utils.h   |    1 -
 3 files changed, 5 insertions(+), 18 deletions(-)

diff --git a/gdb/gdbserver/utils.c b/gdb/gdbserver/utils.c
index 2d0b331..aff95ad 100644
--- a/gdb/gdbserver/utils.c
+++ b/gdb/gdbserver/utils.c
@@ -99,23 +99,6 @@ error (const char *string,...)
 #endif
 }
 
-/* Print an error message and exit reporting failure.
-   This is for a error that we cannot continue from.
-   STRING and ARG are passed to fprintf.  */
-
-/* VARARGS */
-void
-fatal (const char *string,...)
-{
-  va_list args;
-  va_start (args, string);
-  fprintf (stderr, PREFIX);
-  vfprintf (stderr, string, args);
-  fprintf (stderr, "\n");
-  va_end (args);
-  exit (1);
-}
-
 /* VARARGS */
 void
 warning (const char *string,...)
diff --git a/gdb/gdbserver/utils.h b/gdb/gdbserver/utils.h
index 906924b..447a464 100644
--- a/gdb/gdbserver/utils.h
+++ b/gdb/gdbserver/utils.h
@@ -23,7 +23,6 @@
 
 void perror_with_name (const char *string) ATTRIBUTE_NORETURN;
 void error (const char *string,...) ATTRIBUTE_NORETURN ATTRIBUTE_PRINTF (1, 2);
-void fatal (const char *string,...) ATTRIBUTE_NORETURN ATTRIBUTE_PRINTF (1, 2);
 void warning (const char *string,...) ATTRIBUTE_PRINTF (1, 2);
 char *paddress (CORE_ADDR addr);
 char *pfildes (gdb_fildes_t fd);
-- 
1.7.1


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]