From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gnu.wildebeest.org (gnu.wildebeest.org [45.83.234.184]) by sourceware.org (Postfix) with ESMTPS id 957A7387385B for ; Tue, 13 Dec 2022 16:49:51 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 957A7387385B Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=klomp.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=klomp.org Received: from tarox.wildebeest.org (83-87-18-245.cable.dynamic.v4.ziggo.nl [83.87.18.245]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by gnu.wildebeest.org (Postfix) with ESMTPSA id 8A84C3045FA6; Tue, 13 Dec 2022 17:49:50 +0100 (CET) Received: by tarox.wildebeest.org (Postfix, from userid 1000) id EFFE840007AE; Tue, 13 Dec 2022 17:49:49 +0100 (CET) Message-ID: Subject: Re: [PATCH] libdwfl: Read no more than required to parse dynamic sections From: Mark Wielaard To: Gavin Li Cc: elfutils-devel@sourceware.org Date: Tue, 13 Dec 2022 17:49:49 +0100 In-Reply-To: References: <20221129062653.298772-1-gavin@matician.com> <70c0b7df5c6b38492a0655c0ff552453d9dc1f5d.camel@klomp.org> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Evolution 3.28.5 (3.28.5-10.el7) Mime-Version: 1.0 X-Spam-Status: No, score=-3032.7 required=5.0 tests=BAYES_00,JMQ_SPF_NEUTRAL,KAM_DMARC_STATUS,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Hi Gavin, On Thu, 2022-12-01 at 13:13 -0800, Gavin Li wrote: > Awesome, thanks for looking over this. I only have one comment: > there's an extra "xlatefrom.d_size =3D xlatefrom.d_size;" line that > should be removed. Thanks for spotting that. Odd the compiler didn't warn for that. There is a xlatefrom.d_size =3D phnum * phentsize; just before this that does the correct assignment. Pushed with that line removed. Cheers, Mark