projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
a5761de
)
Event-client: in sort of uncasual timeout use our regular timeout handler instead...
author
Wilfried Goesgens
<dothebart@citadel.org>
Sun, 11 Mar 2012 22:09:01 +0000
(23:09 +0100)
committer
Wilfried Goesgens
<dothebart@citadel.org>
Sun, 11 Mar 2012 22:09:01 +0000
(23:09 +0100)
citadel/event_client.c
patch
|
blob
|
history
diff --git
a/citadel/event_client.c
b/citadel/event_client.c
index 19e0458367d43be834ec212d07162c6132ea2140..9f01e9a4aeddb193026e3411858c0b7e48a9718b 100644
(file)
--- a/
citadel/event_client.c
+++ b/
citadel/event_client.c
@@
-71,6
+71,8
@@
#include "event_client.h"
#include "ctdl_module.h"
#include "event_client.h"
#include "ctdl_module.h"
+static void IO_Timeout_callback(struct ev_loop *loop, ev_timer *watcher, int revents);
+
static void IO_abort_shutdown_callback(struct ev_loop *loop,
ev_cleanup *watcher,
int revents)
static void IO_abort_shutdown_callback(struct ev_loop *loop,
ev_cleanup *watcher,
int revents)
@@
-441,6
+443,8
@@
IO_send_callback(struct ev_loop *loop, ev_io *watcher, int revents)
case eSendFile:
if (IO->IOB.ChunkSendRemain > 0) {
ev_io_start(event_base, &IO->recv_event);
case eSendFile:
if (IO->IOB.ChunkSendRemain > 0) {
ev_io_start(event_base, &IO->recv_event);
+ SetNextTimeout(IO, 100.0);
+
} else {
assert(IO->ReadDone);
IO->NextState = IO->ReadDone(IO);
} else {
assert(IO->ReadDone);
IO->NextState = IO->ReadDone(IO);
@@
-500,8
+504,7
@@
IO_send_callback(struct ev_loop *loop, ev_io *watcher, int revents)
}
}
else if (rc < 0) {
}
}
else if (rc < 0) {
- assert(IO->Timeout);
- IO->Timeout(IO);
+ IO_Timeout_callback(loop, &IO->rw_timeout, revents);
}
/* else : must write more. */
}
}
/* else : must write more. */
}