From f02ab90ca9c8493832841b0bea0dd43ea9fbcbce Mon Sep 17 00:00:00 2001 From: Wang Han <416810799@qq.com> Date: Tue, 25 Mar 2025 21:09:29 +0800 Subject: [PATCH] Fix su --shell argument handling (#2529) This fixes https://github.com/tiann/KernelSU/issues/2523. --- userspace/ksud/src/su.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/userspace/ksud/src/su.rs b/userspace/ksud/src/su.rs index 8d79c6ca..50c458ab 100644 --- a/userspace/ksud/src/su.rs +++ b/userspace/ksud/src/su.rs @@ -104,10 +104,11 @@ pub fn root_shell() -> Result<()> { "preserve-environment", "preserve the entire environment", ); - opts.optflag( + opts.optopt( "s", "shell", "use SHELL instead of the default /system/bin/sh", + "SHELL", ); opts.optflag("v", "version", "display version number and exit"); opts.optflag("V", "", "display version code and exit");