[PATCH] disable_ptrace_get_syscall_info, disable_ptrace_getregset: require fork()

Dmitry V. Levin ldv at altlinux.org
Fri Mar 12 01:19:44 UTC 2021


On Thu, Mar 11, 2021 at 06:51:10AM +0200, Baruch Siach wrote:
> These helper programs require fork(), so they are incompatible with
> no-MMU systems. Make the code depend on HAVE_FORK.
> ---
>  src/disable_ptrace_request.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/src/disable_ptrace_request.c b/src/disable_ptrace_request.c
> index 57163e77f0f4..715006941572 100644
> --- a/src/disable_ptrace_request.c
> +++ b/src/disable_ptrace_request.c
> @@ -41,7 +41,8 @@ init(int argc, char **argv)
>   && defined PR_SET_NO_NEW_PRIVS \
>   && defined PR_SET_SECCOMP \
>   && defined BPF_JUMP \
> - && defined BPF_STMT
> + && defined BPF_STMT \
> + && defined HAVE_FORK
>  
>  static unsigned int
>  get_arch(void)

Applied, thanks.


-- 
ldv


More information about the Strace-devel mailing list