gdb: include gdbsupport/buildargv.h in ser-mingw.c
[binutils-gdb.git] / gdb / exceptions.c
index 52cee4e2f6d73ecdfadde9db9c44f7cc1da26b2a..87a8dc26a5141876eff68cf1751bda1fd977ae98 100644 (file)
@@ -1,6 +1,6 @@
 /* Exception (throw catch) mechanism, for GDB, the GNU debugger.
 
-   Copyright (C) 1986-2020 Free Software Foundation, Inc.
+   Copyright (C) 1986-2022 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -85,7 +85,7 @@ print_exception (struct ui_file *file, const struct gdb_exception &e)
       else
        {
          end++;
-         ui_file_write (file, start, end - start);
+         file->write (start, end - start);
        }
     }                                      
   fprintf_filtered (file, "\n");
@@ -133,17 +133,3 @@ exception_fprintf (struct ui_file *file, const struct gdb_exception &e,
       print_exception (file, e);
     }
 }
-
-/* See exceptions.h.  */
-
-int
-exception_print_same (const struct gdb_exception &e1,
-                     const struct gdb_exception &e2)
-{
-  const char *msg1 = e1.message == nullptr ? "" : e1.what ();
-  const char *msg2 = e2.message == nullptr ? "" : e2.what ();
-
-  return (e1.reason == e2.reason
-         && e1.error == e2.error
-         && strcmp (msg1, msg2) == 0);
-}