diff options
author | Fernando Nasser <fnasser@redhat.com> | 2000-10-13 21:41:21 +0000 |
---|---|---|
committer | Fernando Nasser <fnasser@redhat.com> | 2000-10-13 21:41:21 +0000 |
commit | 40e3f985d2a8082507010fca0a01714f092c47a0 (patch) | |
tree | e9e2b1660b34ca9969d6e47a5243bdffef25e29a /gdb | |
parent | a80aa921bfcae6aa535e3a85701d81c63f2bf77a (diff) | |
download | gdb-40e3f985d2a8082507010fca0a01714f092c47a0.zip gdb-40e3f985d2a8082507010fca0a01714f092c47a0.tar.gz gdb-40e3f985d2a8082507010fca0a01714f092c47a0.tar.bz2 |
2000-10-13 Fernando Nasser <fnasser@cygnus.com>
* remote.c (putpkt_binary): Call read_frame, not getpkt. Log message.
(read_frame): Do not call error() on communication error when
reading checksum, but return failure instead and log message.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/ChangeLog | 6 | ||||
-rw-r--r-- | gdb/remote.c | 10 |
2 files changed, 14 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 9614491..201c57c 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2000-10-13 Fernando Nasser <fnasser@cygnus.com> + + * remote.c (putpkt_binary): Call read_frame, not getpkt. Log message. + (read_frame): Do not call error() on communication error when + reading checksum, but return failure instead and log message. + 2000-10-13 Fernando Nasser <fnasser@totem.to.cygnus.com> * varobj.c (type_changeable): Arrays are not changeable. diff --git a/gdb/remote.c b/gdb/remote.c index b58911c..de99364 100644 --- a/gdb/remote.c +++ b/gdb/remote.c @@ -3796,9 +3796,11 @@ putpkt_binary (char *buf, int cnt) break; /* Retransmit buffer */ case '$': { + if (remote_debug) + fprintf_unfiltered (gdb_stdlog, "Packet instead of Ack, ignoring it\n"); /* It's probably an old response, and we're out of sync. Just gobble up the packet and ignore it. */ - getpkt (junkbuf, sizeof_junkbuf, 0); + read_frame (junkbuf, sizeof_junkbuf); continue; /* Now, go look for + */ } default: @@ -3887,7 +3889,11 @@ read_frame (char *buf, return -1; } else if (check_0 < 0 || check_1 < 0) - error ("Communication error in checksum"); + { + if (remote_debug) + fputs_filtered ("Communication error in checksum\n", gdb_stdlog); + return -1; + } pktcsum = (fromhex (check_0) << 4) | fromhex (check_1); if (csum == pktcsum) |