From: Orjan Friberg Date: Fri, 10 Aug 2001 10:11:14 +0000 (+0000) Subject: 2001-08-10 Orjan Friberg X-Git-Tag: gdb_s390-2001-09-26-branchpoint~9 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=86aeb884afe65a7471181621010fbec3823dd10c;p=thirdparty%2Fbinutils-gdb.git 2001-08-10 Orjan Friberg * remote.c (read_frame): Correct off-by-one error in condition. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index f6ad62c7038..41c1e21c391 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,7 @@ +2001-08-10 Orjan Friberg + + * remote.c (read_frame): Correct off-by-one error in condition. + 2001-08-02 Daniel Jacobowitz * core-regset.c (fetch_core_registers): Remove HAVE_GREGSET_T diff --git a/gdb/remote.c b/gdb/remote.c index be90b2024e8..ecf9afcfea9 100644 --- a/gdb/remote.c +++ b/gdb/remote.c @@ -4189,7 +4189,7 @@ read_frame (char *buf, if (repeat > 0 && repeat <= 255 && bc > 0 - && bc + repeat < sizeof_buf - 1) + && bc + repeat - 1 < sizeof_buf - 1) { memset (&buf[bc], buf[bc - 1], repeat); bc += repeat;