2 .\" This file and its contents are supplied under the terms of the
3 .\" Common Development and Distribution License ("CDDL"), version 1.0.
4 .\" You may only use this file in accordance with the terms of version
7 .\" A full copy of the text of the CDDL should have accompanied this
8 .\" source. A copy of the CDDL is also available via the Internet at
9 .\" http://www.illumos.org/license/CDDL.
12 .\" Copyright 2015 Joyent, Inc.
20 .Nd read data from a process
26 .Fa "struct ps_prochandle *P"
29 .Fa "uintptr_t address"
33 .Fa "struct ps_prochandle *P"
36 .Fa "uintptr_t address"
41 function reads data from the process handle
45 in the address space of the process and reads at most
49 and is logically analogous to the
53 For live processes, this function is equivalent to reading from the /proc file
57 For core files and file handles, it reads and writes from the logical address
58 space and not the corresponding offset of the file itself.
59 For example, a core file contains a sparse representation of the address space
60 of a crashed process and unmapped regions are not present in the file.
63 still refers to the virtual addresses that were present at run-time and
64 not those in the core file.
68 function is similar to the
70 function, except that it attempts to interpret
72 as a null terminated character string and will stop reading characters
77 has been read or a null terminator is encountered.
80 will always be null terminated, even if no null terminator was found in
85 Upon successful completion, the
89 functions return a non-negative integer indicating the number of bytes
91 Otherwise, the functions return
95 to indicate the error.
97 For a full list of possible errors also see the
106 .Sh INTERFACE STABILITY