File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -11,13 +11,23 @@ extern "C" {
11
11
}
12
12
13
13
#[ derive( Debug ) ]
14
+ #[ cfg( not( target_arch = "aarch64" ) ) ]
14
15
#[ repr( C , packed) ]
15
16
pub struct Event {
16
17
pub ( crate ) events : u32 ,
17
18
// Token to identify event
18
19
pub ( crate ) epoll_data : usize ,
19
20
}
20
21
22
+ #[ derive( Debug ) ]
23
+ #[ cfg( target_arch = "aarch64" ) ]
24
+ #[ repr( C ) ]
25
+ pub struct Event {
26
+ pub ( crate ) events : u32 ,
27
+ // Token to identify event
28
+ pub ( crate ) epoll_data : usize ,
29
+ }
30
+
21
31
impl Event {
22
32
pub fn token ( & self ) -> usize {
23
33
self . epoll_data
Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ fn handle_events(
49
49
50
50
loop {
51
51
match streams[ index] . read ( & mut data) {
52
- Ok ( n ) if n == 0 => {
52
+ Ok ( 0 ) => {
53
53
// FIX #4
54
54
// `insert` returns false if the value already existed in the set. We
55
55
// handle it here since we must be sure that the TcpStream is fully
You can’t perform that action at this time.
0 commit comments