From f7630ec9c5484b21cddcf50beb1042bffc9160a2 Mon Sep 17 00:00:00 2001 From: Rob Savoye Date: Wed, 9 Jun 1993 01:18:26 +0000 Subject: [PATCH] * serial.c (serial_close): If scb is NULL, don't try to close it. * configure.in: Add support for rom68k and bug boot monitors. --- gdb/ChangeLog | 6 ++++++ gdb/serial.c | 8 +++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 3f0cf78ebba..c6926a4cfb1 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +Tue Jun 8 17:54:09 1993 Rob Savoye (rob@rtl.cygnus.com) + + * serial.c (serial_close): If scb is NULL, don't try to close + it. + * configure.in: Add support for rom68k and bug boot monitors. + Tue Jun 8 17:39:12 1993 Steve Chamberlain (sac@phydeaux.cygnus.com) * coffread.c (init_stringtab): Fix bug where sizeof(long) != 4. diff --git a/gdb/serial.c b/gdb/serial.c index 0e5a064b253..005c946e9c1 100644 --- a/gdb/serial.c +++ b/gdb/serial.c @@ -116,9 +116,11 @@ serial_close(scb) { last_serial_opened = NULL; - scb->ops->close(scb); - - free(scb); + if (scb != NULL) + { + scb->ops->close(scb); + free(scb); + } } #if 0 -- 2.30.2