equal
deleted
inserted
replaced
72 const struct error_info* sock_stream_error (struct sock_stream *sock) |
72 const struct error_info* sock_stream_error (struct sock_stream *sock) |
73 { |
73 { |
74 // return pointer |
74 // return pointer |
75 return SOCK_ERR(sock); |
75 return SOCK_ERR(sock); |
76 } |
76 } |
|
77 |
|
78 void sock_stream_invoke_callbacks (struct sock_stream *sock, short what) |
|
79 { |
|
80 if (what & EV_READ && sock->cb_info->on_read) |
|
81 sock->cb_info->on_read(sock, sock->cb_arg); |
|
82 |
|
83 if (what & EV_WRITE && sock->cb_info->on_write) |
|
84 sock->cb_info->on_read(sock, sock->cb_arg); |
|
85 } |