[patch] Crashed cross gdb/MinGW host

Masaki Muranaka monaka@monami-software.com
Fri May 19 10:45:00 GMT 2006


My sh-elf-gdb on MinGW host was crashed
when I tried to debug using the serial connection.
Here is a patch.

It's possible the another plan to remove writefds
check. There is no support yet for writefds.


- - - -
2006-05-19	Masaki Muranaka <monaka@monami-software.com>
    * mingw-hdep.c (gdb_select)
      Add check if writefds is not NULL.
- - - -
Index: mingw-hdep.c
===================================================================
RCS file: /cvs/src/src/gdb/mingw-hdep.c,v
retrieving revision 1.3
diff -u -p -r1.3 mingw-hdep.c
--- mingw-hdep.c        24 Apr 2006 21:00:13 -0000      1.3
+++ mingw-hdep.c        19 May 2006 09:35:32 -0000
@@ -169,7 +169,7 @@ gdb_select (int n, fd_set *readfds, fd_s
        HANDLE fd_h;
        struct serial *scb;
-      if (!FD_ISSET (fd, readfds) && !FD_ISSET (fd, writefds))
+      if (!FD_ISSET (fd, readfds) && !(writefds && FD_ISSET (fd,  
writefds)))
         continue;
        if (FD_ISSET (fd, readfds))

--
Masaki Muranaka
Monami software




More information about the Gdb-patches mailing list