@@ -91,7 +91,7 @@ pub fn pread(fd: RawFd, buf: &mut [u8], offset: off_t) -> Result<usize>{
91
91
/// therefore not represented in Rust by an actual slice as `IoVec` is. It
92
92
/// is used with [`process_vm_readv`](fn.process_vm_readv.html)
93
93
/// and [`process_vm_writev`](fn.process_vm_writev.html).
94
- #[ cfg( target_os = "linux" ) ]
94
+ #[ cfg( any ( target_os = "linux" , target_os = "android" ) ) ]
95
95
#[ repr( C ) ]
96
96
#[ derive( Clone , Copy , Debug , Eq , Hash , PartialEq ) ]
97
97
pub struct RemoteIoVec {
@@ -115,13 +115,13 @@ pub struct RemoteIoVec {
115
115
/// `CAP_SYS_PTRACE`), or you must be running as the same user as the
116
116
/// target process and the OS must have unprivileged debugging enabled.
117
117
///
118
- /// This function is only available on Linux.
118
+ /// This function is only available on Linux and Android(SDK23+) .
119
119
///
120
120
/// [`process_vm_writev`(2)]: https://man7.org/linux/man-pages/man2/process_vm_writev.2.html
121
121
/// [ptrace]: ../ptrace/index.html
122
122
/// [`IoVec`]: struct.IoVec.html
123
123
/// [`RemoteIoVec`]: struct.RemoteIoVec.html
124
- #[ cfg( target_os = "linux" ) ]
124
+ #[ cfg( any ( target_os = "linux" , target_os = "android" ) ) ]
125
125
pub fn process_vm_writev (
126
126
pid : crate :: unistd:: Pid ,
127
127
local_iov : & [ IoVec < & [ u8 ] > ] ,
@@ -150,13 +150,13 @@ pub fn process_vm_writev(
150
150
/// `CAP_SYS_PTRACE`), or you must be running as the same user as the
151
151
/// target process and the OS must have unprivileged debugging enabled.
152
152
///
153
- /// This function is only available on Linux.
153
+ /// This function is only available on Linux and Android(SDK23+) .
154
154
///
155
155
/// [`process_vm_readv`(2)]: https://man7.org/linux/man-pages/man2/process_vm_readv.2.html
156
156
/// [`ptrace`]: ../ptrace/index.html
157
157
/// [`IoVec`]: struct.IoVec.html
158
158
/// [`RemoteIoVec`]: struct.RemoteIoVec.html
159
- #[ cfg( any( target_os = "linux" ) ) ]
159
+ #[ cfg( any( target_os = "linux" , target_os = "android" ) ) ]
160
160
pub fn process_vm_readv (
161
161
pid : crate :: unistd:: Pid ,
162
162
local_iov : & [ IoVec < & mut [ u8 ] > ] ,
0 commit comments