[10/11] Remove unused deprecated_ui_load_progress_hook

Message ID 20170228145016.22604-11-prudo@linux.vnet.ibm.com
State New, archived
Headers

Commit Message

Philipp Rudo Feb. 28, 2017, 2:50 p.m. UTC
  Nobody actually uses this hook anymore. So simply remove it.

gdb/ChangeLog

	* defs.h (deprecated_ui_load_progress_hook): Remove.
	* symfile.c (deprecated_ui_load_progress_hook): Remove.
	(load_progress): Adjust.
---
 gdb/defs.h    | 3 ---
 gdb/symfile.c | 7 +------
 2 files changed, 1 insertion(+), 9 deletions(-)
  

Patch

diff --git a/gdb/defs.h b/gdb/defs.h
index b7df0dc..e15ddf7 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -673,9 +673,6 @@  extern void (*deprecated_print_frame_info_listing_hook) (struct symtab * s,
 extern int (*deprecated_query_hook) (const char *, va_list)
      ATTRIBUTE_FPTR_PRINTF(1,0);
 
-extern int (*deprecated_ui_load_progress_hook) (const char *section,
-						unsigned long num);
-
 /* If this definition isn't overridden by the header files, assume
    that isatty and fileno exist on this system.  */
 #ifndef ISATTY
diff --git a/gdb/symfile.c b/gdb/symfile.c
index a749a2c..bc85c1b 100644
--- a/gdb/symfile.c
+++ b/gdb/symfile.c
@@ -65,8 +65,6 @@ 
 
 #include "psymtab.h"
 
-int (*deprecated_ui_load_progress_hook) (const char *section,
-					 unsigned long num);
 void (*deprecated_show_load_progress) (const char *section,
 			    unsigned long section_sent,
 			    unsigned long section_size,
@@ -1968,10 +1966,7 @@  load_progress (ULONGEST bytes, void *untyped_arg)
   args->buffer += bytes;
   totals->write_count += 1;
   args->section_sent += bytes;
-  if (check_quit_flag ()
-      || (deprecated_ui_load_progress_hook != NULL
-	  && deprecated_ui_load_progress_hook (args->section_name,
-					       args->section_sent)))
+  if (check_quit_flag ())
     error (_("Canceled the download"));
 
   if (deprecated_show_load_progress != NULL)