nx_proc_ctl_cmdl.nx
buildroot/runtime/nx_proc_ctl_cmdl.nx
about
nx_proc_ctl.nx -- canonical sovereign process control: kill by FULL /proc/<pid>/cmdline. THE one true copy that
replaces (a) nx_proc_kill.nx's /proc/<pid>/comm match -- the 15-char-TRUNCATED field that silently matched nothing
for long names = the 2026-06-29 gallery-login disaster -- and (b) the buried-in-nx_hostctl hc_kill_by_cmdline.
IMPORTABLE (no main, no self-test). Matches "/"+name -> the binary PATH, never an arg mention (so it can't kill its
own command line); signal is a parameter (9=SIGKILL, 15=SIGTERM); returns the HONEST killed count (0 => nothing
matched => the op did nothing). Bounded reader (fixed reused buffers; no sys_read_file 4GiB-per-call leak).
license_tier: ORIGINAL
dependencies 1 imports · 1 importers
imports: nx_syscalls.nx
imported by: nx_proc_ctl_gate.nx
structs
| none |
consts
| 9 | const K_MAGIC_65536: i64 = 65536 |
| 10 | const K_MAGIC_8192: i64 = 8192 |
| 11 | const K_MAGIC_8191: i64 = 8191 |
functions
| 14 | func nx_pctl_cmdl_has(buf: *u8, n: i64, name: *u8) -> i64 |
| 30 | func nx_pctl_kill_by_cmdline(name: *u8, sig: i64) -> i64 |