Fixed event-1.4
This commit is contained in:
parent
b260e04461
commit
9a9f8d048d
4
net.c
4
net.c
@ -477,6 +477,10 @@ static void try_read (struct connection *c) {
|
|||||||
if (!c->in_tail) {
|
if (!c->in_tail) {
|
||||||
c->in_head = c->in_tail = new_connection_buffer (1 << 20);
|
c->in_head = c->in_tail = new_connection_buffer (1 << 20);
|
||||||
}
|
}
|
||||||
|
#ifdef EVENT_V1
|
||||||
|
struct timeval tv = {5, 0};
|
||||||
|
event_add (c->read_ev, &tv);
|
||||||
|
#endif
|
||||||
int x = 0;
|
int x = 0;
|
||||||
while (1) {
|
while (1) {
|
||||||
int r = read (c->fd, c->in_tail->wptr, c->in_tail->end - c->in_tail->wptr);
|
int r = read (c->fd, c->in_tail->wptr, c->in_tail->end - c->in_tail->wptr);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user