From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 8F9A63858283; Mon, 25 Mar 2024 14:20:17 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8F9A63858283 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1711376417; bh=MUba7LtYnTtOfHVnY/pqe62flqTBvOC793eFCjMwyns=; h=From:To:Subject:Date:In-Reply-To:References:From; b=hzNHQr3HuIJ5DINr2YnVTB8o7yCv8KQ1DSmtB+p+qEDSYTIqoknPacZ+V/HmHLeHO xcd/KiCKPN9DWQCHCChmW0JW2jdWm2msKjJhPRWA02ShWQhSojm/AGq5xrDhfv09PX Utft7ZocwnIYMmHNnWC5hMPf7yAJvisN4W2tkSRg= From: "cvs-commit at gcc dot gnu.org" To: glibc-bugs@sourceware.org Subject: [Bug dynamic-link/31317] [RISCV] static PIE crashes during self relocation Date: Mon, 25 Mar 2024 14:20:17 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: dynamic-link X-Bugzilla-Version: 2.39 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://sourceware.org/bugzilla/show_bug.cgi?id=3D31317 --- Comment #7 from Sourceware Commits --- The master branch has been updated by Andreas Schwab : https://sourceware.org/git/gitweb.cgi?p=3Dglibc.git;h=3D96d1b9ac2321b565f34= 0ba8f3674597141e3450d commit 96d1b9ac2321b565f340ba8f3674597141e3450d Author: Palmer Dabbelt Date: Thu Feb 22 15:24:00 2024 -0800 RISC-V: Fix the static-PIE non-relocated object check The value of l_scope is only valid post relocation, so this original check was triggering undefined behavior. Instead just directly check to see if the object has been relocated, at which point using l_scope is safe. Reported-by: Andreas Schwab Closes: BZ #31317 Fixes: e0590f41fe ("RISC-V: Enable static-pie.") Signed-off-by: Palmer Dabbelt --=20 You are receiving this mail because: You are on the CC list for the bug.=