From patchwork Fri Mar 17 06:32:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: stsp X-Patchwork-Id: 66497 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id A0AB0385086D for ; Fri, 17 Mar 2023 06:32:59 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A0AB0385086D DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1679034779; bh=yR1GAZF89e7Qg2UdhUf8n6NIlmuiTcxb4l8n6B4HsTc=; h=To:Cc:Subject:Date:In-Reply-To:References:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=o2AGP+Jd8rMmMnE1ALa418v9G2Xo0gGo3dsfNZMkbd/ChgGm5IQB7xGjID8BMA/p7 aAIlkkZp3MPymJxTy1nXHoyYBYtRzi0sGlW3P46R17xEZlsjlVTz9H15+vDTsgn1pW xF6DNmgbpT7QzJq7pCW/uhnhbkCqQs0UVwZwxhqU= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from forward104p.mail.yandex.net (forward104p.mail.yandex.net [77.88.28.107]) by sourceware.org (Postfix) with ESMTPS id CC4913858438 for ; Fri, 17 Mar 2023 06:32:31 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org CC4913858438 Received: from sas9-2d24a7e69f58.qloud-c.yandex.net (sas9-2d24a7e69f58.qloud-c.yandex.net [IPv6:2a02:6b8:c11:2298:0:640:2d24:a7e6]) by forward104p.mail.yandex.net (Yandex) with ESMTP id C17313C2123C for ; Fri, 17 Mar 2023 09:32:30 +0300 (MSK) Received: by sas9-2d24a7e69f58.qloud-c.yandex.net (smtp/Yandex) with ESMTPSA id QWeJF9abi0U1-BH63QUxH; Fri, 17 Mar 2023 09:32:30 +0300 X-Yandex-Fwd: 1 To: libc-alpha@sourceware.org Cc: Stas Sergeev Subject: [PATCH 03/11] elf: dont pass fd to _dl_process_pt_xx Date: Fri, 17 Mar 2023 11:32:02 +0500 Message-Id: <20230317063210.4118076-4-stsp2@yandex.ru> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20230317063210.4118076-1-stsp2@yandex.ru> References: <20230317063210.4118076-1-stsp2@yandex.ru> MIME-Version: 1.0 X-Spam-Status: No, score=-10.5 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, 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 X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Stas Sergeev via Libc-alpha From: stsp Reply-To: Stas Sergeev Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" It is not used in these functions. rtld.c:rtld_setup_main_map() does the same. The test-suite was run on x86_64/64 and showed no regressions. Signed-off-by: Stas Sergeev --- elf/dl-load.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/elf/dl-load.c b/elf/dl-load.c index fcb39a78d4..ab8b648687 100644 --- a/elf/dl-load.c +++ b/elf/dl-load.c @@ -1379,10 +1379,10 @@ cannot enable executable stack as shared object requires"); switch (ph[-1].p_type) { case PT_NOTE: - _dl_process_pt_note (l, fd, &ph[-1]); + _dl_process_pt_note (l, -1, &ph[-1]); break; case PT_GNU_PROPERTY: - _dl_process_pt_gnu_property (l, fd, &ph[-1]); + _dl_process_pt_gnu_property (l, -1, &ph[-1]); break; }