From: Andreas Schwab Date: Tue, 20 May 2025 14:07:37 +0000 (+0200) Subject: linux-user: implement pgid field of /proc/self/stat X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=19f036726a416c9248c19befe544a2d30b099a25;p=thirdparty%2Fqemu.git linux-user: implement pgid field of /proc/self/stat Signed-off-by: Andreas Schwab Reviewed-by: Richard Henderson Signed-off-by: Richard Henderson Message-ID: --- diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 23b901b713..fc37028597 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -8235,6 +8235,9 @@ static int open_self_stat(CPUArchState *cpu_env, int fd) } else if (i == 3) { /* ppid */ g_string_printf(buf, FMT_pid " ", getppid()); + } else if (i == 4) { + /* pgid */ + g_string_printf(buf, FMT_pid " ", getpgrp()); } else if (i == 19) { /* num_threads */ int cpus = 0;