From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id 994253870886 for ; Tue, 12 May 2020 16:50:20 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 994253870886 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=simark.ca Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=simark@simark.ca Received: from [10.0.0.193] (unknown [192.222.164.54]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by simark.ca (Postfix) with ESMTPSA id BB1701ED39; Tue, 12 May 2020 12:50:19 -0400 (EDT) Subject: Re: [PATCH 4/4] [PR gdbserver/25893]: Add gdbserver test for argument with space in it To: Michael Weghorn , gdb-patches@sourceware.org References: <20200429111638.1327262-1-m.weghorn@posteo.de> <20200429111638.1327262-6-m.weghorn@posteo.de> <1190e73a-8f10-dc6d-4d59-b9a2929530ad@simark.ca> <8839910b-7018-78b7-a46b-7b2bfcb6d2ef@simark.ca> <606608d5-4011-88ef-2d15-f23c04a10810@posteo.de> From: Simon Marchi Message-ID: Date: Tue, 12 May 2020 12:50:19 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: <606608d5-4011-88ef-2d15-f23c04a10810@posteo.de> Content-Type: text/plain; charset=utf-8 Content-Language: tl Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 May 2020 16:50:21 -0000 On 2020-05-12 12:20 p.m., Michael Weghorn via Gdb-patches wrote: > On 11/05/2020 17.04, Simon Marchi wrote: >> On 2020-05-11 10:33 a.m., Michael Weghorn wrote: >>> These don't work yet with the last patch series. I'll recheck once I >>> have finished updating the patch series and in particular fixed the >>> segfault you mentioned earlier. >>> >>> I hope to be able to send an updated patch series tomorrow. >>> >>> Do I understand correctly that I can just drop my patch adding the test, >>> since this is now already covered in a better way by the test case added >>> in your second patch? >> >> I think so. You can insert my two patches in your series, as the test depends >> on the fix. >> >> If you haven't found already: after running the `make check` commands, the >> transcript is found in testsuite/gdb.log. > > Thanks a lot, in particular also for your previous explanations of how > those things work together and how to run the various configurations. > Those really helped in finding out what was going wrong. > > The problem was that 'handle_v_run' in 'gdbserver/server.cc' already had > some special handling for empty args, passing them as "''" into the arg > vector, and 'construct_inferior_arguments' then took this as a literal > string, so the output of the empty argv[2] was "''" instead of "". > > I adapted this in the new version of that patch: > https://sourceware.org/pipermail/gdb-patches/2020-May/168350.html > > All of > > make check TESTS="gdb.base/inferior-args.exp" > RUNTESTFLAGS="--target_board=native-gdbserver" > > make check TESTS="gdb.base/inferior-args.exp" > RUNTESTFLAGS="--target_board=unix" > > make check TESTS="gdb.base/inferior-args.exp" > RUNTESTFLAGS="--target_board=native-extended-gdbserver" > > now pass for me on linux-amd64 (Debian testing) with the new patch set > and your two commits on top. > > I did not explicitly add your commits in the patch series I sent, just > applied them locally (since I was uncertain of how to properly handle > the mismatch between you being the patch author and myself being the > submitter/email sender). If you try to git-send-email a commit for which you are not the "Author", it will still send the email with you as the "From:", but there will be an extra "From:" line in the body, such that when applied, the correct author will be used. In other words, it works to git-send-email patches made by somebody else. Thanks for sending a new version, I'll take a look. Simon