forked from Imagelibrary/binutils-gdb
* remote.c: Add arg names to prototypes, in a modest effort at
clarification. Also add prototypes for some new functions. * (remote_wait): Better error reporting for 'T' responses. * ser-go32.c (strncasecmp): Make str1 & str2 be const. * (dos_async_init): Make usage message reflect requested port #. * ser-tcp.c (tcp_open): Terminate hostname properly to prevent random hostname lookup failures. Add nicer message for unknown host error. (wait_for): Wake up in case of exceptions. Also, restart select() if we got EINTR. * ser-unix.c (wait_for): Restart select() if we got EINTR. * serial.c: (serial_close): Clean up code.
This commit is contained in:
13
gdb/serial.c
13
gdb/serial.c
@@ -116,11 +116,14 @@ serial_close(scb)
|
||||
{
|
||||
last_serial_opened = NULL;
|
||||
|
||||
if (scb != NULL)
|
||||
{
|
||||
scb->ops->close(scb);
|
||||
free(scb);
|
||||
}
|
||||
/* This is bogus. It's not our fault if you pass us a bad scb...! Rob, you
|
||||
should fix your code instead. */
|
||||
|
||||
if (!scb)
|
||||
return;
|
||||
|
||||
scb->ops->close(scb);
|
||||
free(scb);
|
||||
}
|
||||
|
||||
#if 0
|
||||
|
||||
Reference in New Issue
Block a user