From 1ab41359751055dad049c77b2507734ad4840640 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B6nke=20Holz?= Date: Mon, 15 Jan 2024 11:40:20 +0100 Subject: [PATCH] LibC: Pass arguments correctly to sigprocmask in setjmp for riscv64 For some reason I decided to change the argument passing order before submitting my PR, but this would cause the oldset argument to always be 0x74 as a0 is overridden with 0 in that order. --- Userland/Libraries/LibC/arch/riscv64/setjmp.S | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Userland/Libraries/LibC/arch/riscv64/setjmp.S b/Userland/Libraries/LibC/arch/riscv64/setjmp.S index 05090122032..7700d8babbe 100644 --- a/Userland/Libraries/LibC/arch/riscv64/setjmp.S +++ b/Userland/Libraries/LibC/arch/riscv64/setjmp.S @@ -34,9 +34,9 @@ sigsetjmp: sd a0, 0(sp) sd ra, 8(sp) - li a0, 0 // Set argument how - li a1, 0 // Set argument set addi a2, a0, SAVED_SIGNAL_MASK_SLOT // Set argument oldset + li a1, 0 // Set argument set + li a0, 0 // Set argument how call sigprocmask@plt ld ra, 8(sp)