From Eli. Warning fixes.
authorAndrew Cagney <cagney@redhat.com>
Tue, 29 Feb 2000 07:45:13 +0000 (07:45 +0000)
committerAndrew Cagney <cagney@redhat.com>
Tue, 29 Feb 2000 07:45:13 +0000 (07:45 +0000)
gdb/ChangeLog
gdb/expprint.c
gdb/ser-go32.c
gdb/utils.c

index 0d85d02..28484c9 100644 (file)
@@ -1,3 +1,16 @@
+Tue Feb 29 18:40:08 2000  Andrew Cagney  <cagney@b1.cygnus.com>
+
+       From 2000-02-23 Eli Zaretskii <eliz@is.elta.co.il>:
+       * utils.c [__GO32__]: Include pc.h, for prototypes of ScreenCols
+       and ScreenRows.
+       * ser-go32.c: Include string.h, for prototype of strncasecmp.
+       (dpmi_regs, dpmi_sregs): Remove unused variables.
+       (dos_flush_input): Return a value, to prevent compiler warning.
+       * expprint.c (dump_prefix_expression): Use %ld in format and cast
+       sizeof(union exp_element) to long, to prevent GCC from complaining
+       about format/argument mismatch.
+       (dump_postfix_expression): Likewise.
+
 Tue Feb 29 18:09:46 2000  Andrew Cagney  <cagney@b1.cygnus.com>
 
        * arm-tdep.c: Include <ctype.h>.
index 8c0fe4f..4b5245c 100644 (file)
@@ -710,9 +710,9 @@ dump_prefix_expression (exp, stream, note)
     print_expression (exp, stream);
   else
     fprintf_filtered (stream, "Type printing not yet supported....");
-  fprintf_filtered (stream, "'\n\tLanguage %s, %d elements, %d bytes each.\n",
+  fprintf_filtered (stream, "'\n\tLanguage %s, %d elements, %ld bytes each.\n",
                    exp->language_defn->la_name, exp->nelts,
-                   sizeof (union exp_element));
+                   (long) sizeof (union exp_element));
   fprintf_filtered (stream, "\t%5s  %20s  %16s  %s\n", "Index", "Opcode",
                    "Hex Value", "String Value");
   for (elt = 0; elt < exp->nelts; elt++)
@@ -986,9 +986,9 @@ dump_postfix_expression (exp, stream, note)
     print_expression (exp, stream);
   else
     fputs_filtered ("Type printing not yet supported....", stream);
-  fprintf_filtered (stream, "'\n\tLanguage %s, %d elements, %d bytes each.\n",
+  fprintf_filtered (stream, "'\n\tLanguage %s, %d elements, %ld bytes each.\n",
                    exp->language_defn->la_name, exp->nelts,
-                   sizeof (union exp_element));
+                   (long) sizeof (union exp_element));
   fputs_filtered ("\n", stream);
 
   for (elt = 0; elt < exp->nelts;)
index 94a7861..0474000 100644 (file)
 #define        MSR_DDSR        0x02
 #define        MSR_DCTS        0x01
 
+#include <string.h>
 #include <dos.h>
 #include <go32.h>
 #include <dpmi.h>
 typedef unsigned long u_long;
 
-/* DPMI Communication */
-static union REGS dpmi_regs;
-static struct SREGS dpmi_sregs;
-
 /* 16550 rx fifo trigger point */
 #define FIFO_TRIGGER   FIFO_TRIGGER_4
 
@@ -693,6 +690,7 @@ dos_flush_input (scb)
   if (port->fifo)
     outb (port, com_fifo, FIFO_ENABLE | FIFO_RCV_RST | FIFO_TRIGGER);
   enable ();
+  return 0;
 }
 
 static void
index 2c8d402..501c861 100644 (file)
 #include <term.h>
 #endif
 
+#ifdef __GO32__
+#include <pc.h>
+#endif
+
 /* SunOS's curses.h has a '#define reg register' in it.  Thank you Sun. */
 #ifdef reg
 #undef reg