From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from eggs.gnu.org (eggs.gnu.org [IPv6:2001:470:142:3::10]) by sourceware.org (Postfix) with ESMTPS id 5D2E33858C31 for ; Thu, 14 Mar 2024 15:07:58 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 5D2E33858C31 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gnu.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gnu.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 5D2E33858C31 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2001:470:142:3::10 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1710428880; cv=none; b=YyHA57LhLqQpskAskwtkfiGEgld245BrP11CmwUOdMI6OUkSoKnaRFI+ssufEunBqZYuUfoG6Cq/MEj6CEhR7tQ7Xlsw2dnRvQF9KjyTSc1ipKn6z8QTpfIRYhWz8+1iWiyhPv62RTiCoawHooRKDhKuglTcsm5S/XJRVXsyhlw= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1710428880; c=relaxed/simple; bh=WQ72C228TSCy71+KA128foUKfbqvtOxRHUb2yC/m+7U=; h=DKIM-Signature:Date:Message-Id:From:To:Subject; b=FkTG0+Y26iOpgPwIWPai25Sxt1dfI95ZiRyjulqclayhmFxrSwOaHs6YzS8qyEqzwfy92av6zwoOBbkkxNRUg9ebsE422tnIape5a6sYHMq1nJjtrOZky1Cmo4TcsW3aEjzTopmOJLz+v1YO7F+wd+CRemgeiLngD+1HxamAYEg= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rkmgU-0000X4-Dy; Thu, 14 Mar 2024 11:07:55 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=QIvHsy1sWjInwEv6X9CGAEfrEOPVRgTaurQn8DD1CpM=; b=U0t4xLGs75bQ eiGl8m0ujC7orzi96OROoQP/3OjGcaD+pPfm/SGoJ4fcqXEHkzsAPaYrnxsVOwZmZ4AG5W6vmOkdR rsMWKz8WhTpgivAB3enQfZBBREoCsfgT/1y+vfp/a+8qo9r0l1m2IOJPKf55bdeJDPYwiIqXeMPN0 eCy8QrzWFUTQKUpTGlxM66k7x4cGq5+pMncsePimIGMHluccWtf6G76URrejjxJXxFqVEIG/KLKhS Vjp6mhkwP/Xdt/4Q0fGffvvMfIXJVPyXWHs+I3tvvCN4XmkBVeQ1zfjk3y+j/vwpqSB/gmpGX3F5e PiphbtCnjAdau0oZ0PMSlQ==; Date: Thu, 14 Mar 2024 17:07:40 +0200 Message-Id: <86edccam2r.fsf@gnu.org> From: Eli Zaretskii To: Tankut Baris Aktemur Cc: gdb-patches@sourceware.org, tom@tromey.com In-Reply-To: <2df4539dd59feb3b70f15ed679563a85bb286075.1710420898.git.tankut.baris.aktemur@intel.com> (message from Tankut Baris Aktemur on Thu, 14 Mar 2024 14:07:30 +0100) Subject: Re: [PATCH v2 3/4] rsp: add 'E' to escaped characters References: <2df4539dd59feb3b70f15ed679563a85bb286075.1710420898.git.tankut.baris.aktemur@intel.com> X-Spam-Status: No, score=-6.2 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,SPF_HELO_PASS,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: > From: Tankut Baris Aktemur > Cc: tom@tromey.com > Date: Thu, 14 Mar 2024 14:07:30 +0100 > > Add 'E' to the list of escaped characters when sending/receiving > binary data. This is a preparation for the next patch, to be able to > distinguish an error response from binary data that starts with 'E'. > > Approved-By: Tom Tromey > --- > gdb/doc/gdb.texinfo | 4 +++- > gdbsupport/rsp-low.cc | 2 +- > 2 files changed, 4 insertions(+), 2 deletions(-) Thanks. > diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo > index f2b80db94ef..9a7d61be65e 100644 > --- a/gdb/doc/gdb.texinfo > +++ b/gdb/doc/gdb.texinfo > @@ -42389,7 +42389,9 @@ bytes @code{0x7d 0x5d}. The bytes @code{0x23} (@sc{ascii} @samp{#}), > @samp{@}}) must always be escaped. Responses sent by the stub > must also escape @code{0x2a} (@sc{ascii} @samp{*}), so that it > is not interpreted as the start of a run-length encoded sequence > -(described next). > +(described next). The @code{0x45} (@sc{ascii} @samp{E}) byte should > +also be escaped to distinguish it from an error reply that starts with > +the @samp{E} character. > > Response @var{data} can be run-length encoded to save space. > Run-length encoding replaces runs of identical characters with one This part is okay. Reviewed-By: Eli Zaretskii