Trivial patch to remove dependency on host unsigned long type
[deliverable/binutils-gdb.git] / gdb / event-top.c
index 1b75bbd806cf1352c223669096de5d38b4656df0..f1d55b3c2daec5c60926ccfd405db94e9b482aba 100644 (file)
@@ -35,6 +35,8 @@
 #include "observer.h"
 #include "continuations.h"
 #include "gdbcmd.h"            /* for dont_repeat() */
+#include "annotate.h"
+#include "maint.h"
 
 /* readline include files.  */
 #include "readline/readline.h"
@@ -231,6 +233,8 @@ display_gdb_prompt (char *new_prompt)
   char *actual_gdb_prompt = NULL;
   struct cleanup *old_chain;
 
+  annotate_display_prompt ();
+
   /* Reset the nesting depth used when trace-commands is set.  */
   reset_command_nest_depth ();
 
@@ -265,6 +269,7 @@ display_gdb_prompt (char *new_prompt)
             rl_callback_handler_remove(), does the job.  */
 
          rl_callback_handler_remove ();
+         do_cleanups (old_chain);
          return;
        }
       else
@@ -450,8 +455,6 @@ command_line_handler (char *rl)
   char *p;
   char *p1;
   char *nline;
-  char got_eof = 0;
-
   int repeat = (instream == stdin);
 
   if (annotation_level > 1 && instream == stdin)
@@ -496,7 +499,6 @@ command_line_handler (char *rl)
      and exit from gdb.  */
   if (!rl || rl == (char *) EOF)
     {
-      got_eof = 1;
       command_handler (0);
       return;                  /* Lint.  */
     }
@@ -867,7 +869,7 @@ async_disconnect (gdb_client_data arg)
 
   TRY_CATCH (exception, RETURN_MASK_ALL)
     {
-      pop_all_targets (1);
+      pop_all_targets ();
     }
 
   signal (SIGHUP, SIG_DFL);    /*FIXME: ???????????  */
@@ -953,7 +955,7 @@ gdb_setup_readline (void)
      time.  */
   if (!batch_silent)
     gdb_stdout = stdio_fileopen (stdout);
-  gdb_stderr = stdio_fileopen (stderr);
+  gdb_stderr = stderr_fileopen ();
   gdb_stdlog = gdb_stderr;  /* for moment */
   gdb_stdtarg = gdb_stderr; /* for moment */
   gdb_stdtargerr = gdb_stderr; /* for moment */
This page took 0.027858 seconds and 4 git commands to generate.