From: Thiago Jung Bauermann Date: Sat, 5 Oct 2024 04:26:53 +0000 (-0300) Subject: GDB: remote: Print total bytes received in debug message X-Git-Tag: binutils-2_44~215 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1f493519f703220bc072538ce3586f7363eba904;p=thirdparty%2Fbinutils-gdb.git GDB: remote: Print total bytes received in debug message This is useful information I missed while debugging issues with the g packet reply. Reviewed-By: Tankut Baris Aktemur Approved-By: Simon Marchi --- diff --git a/gdb/remote.c b/gdb/remote.c index d9ad6974366..8cb9050eaed 100644 --- a/gdb/remote.c +++ b/gdb/remote.c @@ -10539,8 +10539,8 @@ remote_target::getpkt (gdb::char_vector *buf, bool forever, bool *is_notif) if (val > max_chars) remote_debug_printf_nofunc - ("Packet received: %s [%d bytes omitted]", str.c_str (), - val - max_chars); + ("Packet received: %s [%d of %d bytes omitted]", str.c_str (), + val - max_chars, val); else remote_debug_printf_nofunc ("Packet received: %s", str.c_str ());