aboutsummaryrefslogtreecommitdiff
path: root/gdb/ser-tcp.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@adacore.com>2023-08-29 07:20:22 -0600
committerTom Tromey <tromey@adacore.com>2023-11-27 12:55:14 -0700
commitad3cf8c64e6e4794fc48d28c90f20cbbfdc51ca4 (patch)
tree8c8c2b1ff861a6a9a2812522fb95ec9e7feec779 /gdb/ser-tcp.c
parent602971b3863dcecf2daa5ffc0853a75a3131446c (diff)
downloadgdb-ad3cf8c64e6e4794fc48d28c90f20cbbfdc51ca4.zip
gdb-ad3cf8c64e6e4794fc48d28c90f20cbbfdc51ca4.tar.gz
gdb-ad3cf8c64e6e4794fc48d28c90f20cbbfdc51ca4.tar.bz2
Change serial_setbaudrate to throw exception
remote.c has this code: if (serial_setbaudrate (rs->remote_desc, baud_rate)) { /* The requested speed could not be set. Error out to top level after closing remote_desc. Take care to set remote_desc to NULL to avoid closing remote_desc more than once. */ serial_close (rs->remote_desc); rs->remote_desc = NULL; perror_with_name (name); The perror here cannot be correct, because if serial_setbaudrate did set errno, it may be obscured by serial_close. This patch changes serial_setbaudrate to throw an exception instead. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=30770
Diffstat (limited to 'gdb/ser-tcp.c')
0 files changed, 0 insertions, 0 deletions