projects
/
pazpar2-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a50d5d4
)
Add client_{lock,unlock} before call to non_block_events
author
Adam Dickmeiss
<adam@indexdata.dk>
Tue, 28 Jan 2014 14:44:07 +0000
(15:44 +0100)
committer
Adam Dickmeiss
<adam@indexdata.dk>
Tue, 28 Jan 2014 14:44:07 +0000
(15:44 +0100)
in connection_continue. Problem is that if non_block_events
fire records, then we will not unlock client at all. And as
a result a dead-lock occurs.
src/connection.c
patch
|
blob
|
history
diff --git
a/src/connection.c
b/src/connection.c
index
5f127ea
..
41e693c
100644
(file)
--- a/
src/connection.c
+++ b/
src/connection.c
@@
-284,7
+284,13
@@
void connection_continue(struct connection *co)
{
int r = ZOOM_connection_exec_task(co->link);
if (!r)
+ {
+ struct client *cl = co->client;
+
+ client_lock(cl);
non_block_events(co);
+ client_unlock(cl);
+ }
else
{
iochan_setflags(co->iochan, ZOOM_connection_get_mask(co->link));