PPLATFORM(3PROC) Process Control Library Functions PPLATFORM(3PROC)

Pplatformget platform string

Process Control Library (libproc, -lproc)

#include <libproc.h>

char *
Pplatform(struct ps_prochandle *P, char *buffer, size_t bufsize);

The () function determines the name of the platform for the process handle P. Up to bufsize characters, including the null terminator, will be copied into buffer.

The platform is the value reported by the option to uname(1). For example, on x86 systems, the value will be .

Note, process handles that correspond to a file, created by Pgrab_file(3PROC), will not report a platform and the () function will fail.

Upon successful completion, the Pplatform() function returns buffer. Otherwise, NULL is returned, is set, and buffer is not updated.

The Pplatform() function will fail if:

P refers to a core file and there is no ELF note available.
P refers to a live process and buffer is an invalid address.

See in libproc(3LIB).

uname(1), sysinfo(2), libproc(3LIB), proc(5)

May 11, 2016 OmniOS