runtime/process_id.ts

Process ID validation shared by the probe_process implementations and their callers.

view source

Declarations
#

3 declarations

assert_process_id
#

runtime/process_id.ts view source

(pid: number): void import {assert_process_id} from '@fuzdev/fuz_app/runtime/process_id.js';

Refuse a pid that doesn't name one process (is_process_id).

pid

the candidate process ID

type number

returns

void

throws

  • RangeError - when `pid` is not a positive integer within `pid_t` range

is_process_id
#

runtime/process_id.ts view source

(pid: number): boolean import {is_process_id} from '@fuzdev/fuz_app/runtime/process_id.js';

Whether pid names one process: a positive integer within pid_t range. 0 and negative numbers name process groups (kill(0, …) signals the caller's own group, kill(-1, …) every process it may signal).

pid

the candidate process ID

type number

returns

boolean

PROCESS_ID_MAX
#

runtime/process_id.ts view source

2147483647 import {PROCESS_ID_MAX} from '@fuzdev/fuz_app/runtime/process_id.js';

The largest process ID: pid_t is a signed 32-bit integer.

Imported by
#