diff options
| author | Po Lu | 2023-05-05 19:04:32 +0800 |
|---|---|---|
| committer | Po Lu | 2023-05-05 19:04:32 +0800 |
| commit | 0fbe79727b07879cb4f0a5cb8d7288353c082bd0 (patch) | |
| tree | 921d949e0403488deba0ae13cc55ef736d095e23 /java | |
| parent | 2ba6c5035c904426d564eac47381480158cbbb9e (diff) | |
| download | emacs-0fbe79727b07879cb4f0a5cb8d7288353c082bd0.tar.gz emacs-0fbe79727b07879cb4f0a5cb8d7288353c082bd0.zip | |
Fix execution of /proc/self/exe within child processes
* exec/exec.h (struct exec_tracee): New field `new_child'.
Also, make `waiting_for_syscall' a bitfield.
* exec/trace.c (PTRACE_GETEVENTMSG): New declaration.
(MAX_TRACEES): Bump to 4096.
(handle_clone_prepare): New function.
(handle_clone): If required, set `new_child' and wait for a
ptrace event describing the parent to arrive.
(after_fork): Clear new field.
(exec_waitpid): Upon a ptrace event describing a clone, create
the child's tracee if it doesn't already exist. Otherwise, copy
over the parent's cmdline and start running it.
Diffstat (limited to 'java')
0 files changed, 0 insertions, 0 deletions