Changeset View
Changeset View
Standalone View
Standalone View
lib/libsys/ptrace.2
| Show First 20 Lines • Show All 845 Lines • ▼ Show 20 Lines | |||||||||
| .It Dv EJUSTRETURN | .It Dv EJUSTRETURN | ||||||||
| System call completed sucessfully but did not set a return value | System call completed sucessfully but did not set a return value | ||||||||
| .Po for example, | .Po for example, | ||||||||
| .Xr setcontext 2 | .Xr setcontext 2 | ||||||||
| and | and | ||||||||
| .Xr sigreturn 2 | .Xr sigreturn 2 | ||||||||
| .Pc . | .Pc . | ||||||||
| .El | .El | ||||||||
| .It Dv PT_SET_SC_RET | |||||||||
| Set the current system call return values. | |||||||||
| This request is only valid for threads stopped in a syscall | |||||||||
| entry (the | |||||||||
| .Dv PL_FLAG_SCE | |||||||||
| state). | |||||||||
| The | |||||||||
| .Fa addr | |||||||||
| argument specifies a pointer to a | |||||||||
| .Vt "struct ptrace_sc_ret" , | |||||||||
| the | |||||||||
| .Fa data | |||||||||
| argument is set to the size of the structure. | |||||||||
markj: The size is not validated anywhere AFAICS. | |||||||||
| .Pp | |||||||||
| The current system call handler is not executed. | |||||||||
| After the thread is resumed, it is returned to userspace. | |||||||||
| with the machine state set as if the handler results were according | |||||||||
| to the passed structure content. | |||||||||
Done Inline ActionsMy suggestion for the last sentence: "After the thread is resumed, it returns to userspace with machine state set as though the system call handler had returned the values passed via the .Fa data argument." markj: My suggestion for the last sentence: "After the thread is resumed, it returns to userspace with… | |||||||||
Done Inline ActionsI replaced it with the slight modification, it is not the 'data'. kib: I replaced it with the slight modification, it is not the 'data'. | |||||||||
| .It Dv PT_FOLLOW_FORK | .It Dv PT_FOLLOW_FORK | ||||||||
| This request controls tracing for new child processes of a traced process. | This request controls tracing for new child processes of a traced process. | ||||||||
Done Inline Actions
markj: | |||||||||
| If | If | ||||||||
| .Fa data | .Fa data | ||||||||
| is non-zero, | is non-zero, | ||||||||
| .Dv PTRACE_FORK | .Dv PTRACE_FORK | ||||||||
| is set in the traced process's event tracing mask. | is set in the traced process's event tracing mask. | ||||||||
| If | If | ||||||||
| .Fa data | .Fa data | ||||||||
| is zero, | is zero, | ||||||||
| ▲ Show 20 Lines • Show All 588 Lines • Show Last 20 Lines | |||||||||
The size is not validated anywhere AFAICS.