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]

DJGPP specific fix for struct serial_ops in ser-go32.c


This is a fix for the DJGPP port of gdb.
I do not know when this has changed but the numbers of arguments passed to
setparity of struct serial_ops no longer match the number of arguments of
dos_noop.  The patch below fixes the issue providing a new dummy function.

Is there some one on this list that is member on the gdb bug mailing list?
I have tried to submitte this mail to bug-gdb@gnu.org but it has been bounced.


Regards,
Juan M. Guerrero



2016-01-10  Juan Manuel Guerrero  <juan.guerrero@gmx.de>

	* gdb/ser-go32.c:  New function dos_setparity_noop.


diff -aprNU5 gdb-7.10.1.orig/gdb/ser-go32.c gdb-7.10.1/gdb/ser-go32.c
--- gdb-7.10.1.orig/gdb/ser-go32.c	2015-11-23 00:42:20 +0100
+++ gdb-7.10.1/gdb/ser-go32.c	2016-01-10 08:24:56 +0100
@@ -593,10 +593,16 @@ dos_close (struct serial *scb)
 }
 


 static int
+dos_setparity_noop (struct serial *scb, int parity)
+{
+  return 0;  /* GO32 doesn't support this */
+}
+
+static int
 dos_noop (struct serial *scb)
 {
   return 0;
 }

@@ -862,11 +868,11 @@ static const struct serial_ops dos_ops =
   dos_set_tty_state,
   dos_print_tty_state,
   dos_noflush_set_tty_state,
   dos_setbaudrate,
   dos_setstopbits,
-  dos_noop,
+  dos_setparity_noop,
   dos_noop,			/* Wait for output to drain.  */
   (void (*)(struct serial *, int))NULL	/* Change into async mode.  */
 };

 int


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