|
From: | Michael Tokarev |
Subject: | Re: [PATCH] linux-user: manage binfmt-misc preserve-arg[0] flag |
Date: | Mon, 22 Feb 2021 17:45:12 +0300 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 |
22.02.2021 13:50, Laurent Vivier wrote:
Add --preserve-argv0 in qemu-binfmt-conf.sh to configure the preserve-argv0 flag. This patch allows to use new flag in AT_FLAGS to detect if preserve-argv0 is configured for this interpreter: argv[0] (the full pathname provided by binfmt-misc) is removed and replaced by argv[1] (the original argv[0] provided by binfmt-misc when 'P'/preserve-arg[0] is set)
A few days ago I sent an RFC patch which fixes this issue without kernel patch, by registering special binary name in binfmt (note: that patch had argv[1] & argv[2] swapped by mistake). Here it is: https://lists.gnu.org/archive/html/qemu-devel/2021-02/msg04639.html /mjt
[Prev in Thread] | Current Thread | [Next in Thread] |