File tree Expand file tree Collapse file tree 1 file changed +19
-1
lines changed
src/unix/notbsd/linux/other Expand file tree Collapse file tree 1 file changed +19
-1
lines changed Original file line number Diff line number Diff line change 48
48
pub si_signo: :: c_int,
49
49
pub si_errno: :: c_int,
50
50
pub si_code: :: c_int,
51
- #[ deprecated( since="0.2.54" , note="Please leave a comment on https://github.com/rust-lang/libc/pull/1316 if you're using this field" ) ]
51
+ #[ deprecated(
52
+ since="0.2.54" ,
53
+ note="Please leave a comment on \
54
+ https://github.com/rust-lang/libc/pull/1316 if you're using \
55
+ this field"
56
+ ) ]
52
57
pub _pad: [ :: c_int; 29 ] ,
53
58
#[ cfg( target_arch = "x86_64" ) ]
54
59
_align: [ u64 ; 0 ] ,
55
60
#[ cfg( not( target_arch = "x86_64" ) ) ]
56
61
_align: [ usize ; 0 ] ,
57
62
}
58
63
64
+ impl siginfo_t {
65
+ pub unsafe fn si_addr( & self ) -> * mut :: c_void {
66
+ #[ repr( C ) ]
67
+ struct siginfo_sigfault {
68
+ _si_signo: :: c_int,
69
+ _si_errno: :: c_int,
70
+ _si_code: :: c_int,
71
+ si_addr: * mut :: c_void
72
+ }
73
+ ( * ( self as * const siginfo_t as * const siginfo_sigfault) ) . si_addr
74
+ }
75
+ }
76
+
59
77
pub struct glob64_t {
60
78
pub gl_pathc: :: size_t,
61
79
pub gl_pathv: * mut * mut :: c_char,
You can’t perform that action at this time.
0 commit comments