From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id 8E9313858C1F for ; Mon, 19 Dec 2022 13:53:55 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 8E9313858C1F Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1671458035; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=EwJv5lfRo2co2JlD5RBcqC2eu3pUtMyk+SNLIS9lONE=; b=MmFlzAtIVBokZor8qZVS/q/MPGNk1UfKWY4qk7d1zLIDrrHbhfi+TS6NXoA5hqZXu8zKxL JiUYbaI6rZUJdaipBkK+n4c7e00BjXRQ/ygvO/bE8sXgvAQzTrQNNpHGzWjioaRH/HeYLk 9gNY0WqbCzFp/0INjbxpf2dXl/kloyg= Received: from mail-ed1-f69.google.com (mail-ed1-f69.google.com [209.85.208.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-619-R8paYlmQMJ-QHKucajHj4g-1; Mon, 19 Dec 2022 08:53:54 -0500 X-MC-Unique: R8paYlmQMJ-QHKucajHj4g-1 Received: by mail-ed1-f69.google.com with SMTP id t17-20020a056402525100b00478b85eecedso3090874edd.18 for ; Mon, 19 Dec 2022 05:53:54 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=EwJv5lfRo2co2JlD5RBcqC2eu3pUtMyk+SNLIS9lONE=; b=F/ojaXur41UoVVk5oUSZnxXGhJ2/ndgMuFj95pu3FHJzST+Jq8AzhnIpAJGZKcRmCq bPfJqvEn6P7nQeyi6g4F5N/dHpbUYHpsbp9DPMLTx5yEYcWC9aR4NeJWGFdRueW/Y8eM BMnMGFMTYi6vmCAuP2/Ir9tmt+MqPOY86vrKoEiYO0j1FyhljqaW981hNONrRBVgq5GX 4eKhllB8cMEogBMXVODIoEg/WLVkl7w5MR5ZaPOWo0JDviitu+tDPkM2sA/hMiXJSIi9 4LWLx01Ct5a+A3ZS47u/5AlhaLo6rfey9xUcvQznlFXiMV7kyTfxUtDXkj4MPytvcCbG 3zjw== X-Gm-Message-State: ANoB5pm38shWtLbl92zF0L4UZ6JSwsFwTuHSw/wgeHRyLOdjSQAY5+2V ce9CKcwuWjdFTOZPE+3qUsedw/d+5XWyu7rbx5WqGTVoWkydp3mFW8oQCtt8N0SHdTo5ZpU2D0v Gxq/NgRfs45H+MpJ2tj5uIQaFddb9y2XiRU4OyDgNX0br/SQNxhnAEa4tg5ejjxmqiAv4 X-Received: by 2002:a17:906:5655:b0:7c1:5464:3360 with SMTP id v21-20020a170906565500b007c154643360mr44269065ejr.65.1671458032935; Mon, 19 Dec 2022 05:53:52 -0800 (PST) X-Google-Smtp-Source: AA0mqf5EWnlxGTI0iQuOsCAVqwbfcAKaKYcRqEBGhz136Tjrg7vT71As05Z+etJTNdSwr14m94K1fQ== X-Received: by 2002:a17:906:5655:b0:7c1:5464:3360 with SMTP id v21-20020a170906565500b007c154643360mr44269041ejr.65.1671458032666; Mon, 19 Dec 2022 05:53:52 -0800 (PST) Received: from ulissedini.. ([81.56.11.23]) by smtp.gmail.com with ESMTPSA id t21-20020a056402021500b00463bc1ddc76sm4377476edv.28.2022.12.19.05.53.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Dec 2022 05:53:52 -0800 (PST) From: Maurizio Papini To: binutils@sourceware.org Cc: Maurizio Papini Subject: [PATCH 2/2] addr2line: test to check -n option Date: Mon, 19 Dec 2022 14:53:03 +0100 Message-Id: <20221219135303.116222-3-mpapini@redhat.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221219135303.116222-1-mpapini@redhat.com> References: <20221219135303.116222-1-mpapini@redhat.com> MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true X-Spam-Status: No, score=-11.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,TXREP 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: --- binutils/testsuite/binutils-all/addr2line.exp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/binutils/testsuite/binutils-all/addr2line.exp b/binutils/testsuite/binutils-all/addr2line.exp index 957ae55df33..59c0924412c 100644 --- a/binutils/testsuite/binutils-all/addr2line.exp +++ b/binutils/testsuite/binutils-all/addr2line.exp @@ -61,6 +61,16 @@ if ![regexp -line "^(\[0-9a-fA-F\]+)? +\[Tt\] ${dot}fn" $output contents] then { pass "$testname -f option" } +#testcase for -n option: check the extra newline +#Using the same fn function address used in -f option. + set got [binutils_run $ADDR2LINE "-n -f -e tmpdir/testprog$exe [lindex $list 0]"] + set want "fn\n$srcdir/$subdir/testprog.c:\[0-9\]+\n\n" + if ![regexp $want $got] then { + fail "$testname -fn option $got\n" + } else { + pass "$testname -fn option" + } + #testcase for -s option. #Using the same fn function address used in -f option. set got [binutils_run $ADDR2LINE "-s -e tmpdir/testprog$exe [lindex $list 0]"] -- 2.38.1