aboutsummaryrefslogtreecommitdiffstats
path: root/tools/xenstore/xenstored_transaction.c
diff options
context:
space:
mode:
authorcl349@firebug.cl.cam.ac.uk <cl349@firebug.cl.cam.ac.uk>2005-07-26 15:26:32 +0000
committercl349@firebug.cl.cam.ac.uk <cl349@firebug.cl.cam.ac.uk>2005-07-26 15:26:32 +0000
commiteb825f79cb6e0939871180692808f241fe5ddc93 (patch)
tree5b67c7f5cb99233e1f683f53266e594f74218c77 /tools/xenstore/xenstored_transaction.c
parentdfc7e02e7ab3715f098e8a6c4105016b0862c5df (diff)
downloadxen-eb825f79cb6e0939871180692808f241fe5ddc93.tar.gz
xen-eb825f79cb6e0939871180692808f241fe5ddc93.tar.bz2
xen-eb825f79cb6e0939871180692808f241fe5ddc93.zip
Remove ill-conceived concept of watches blocking reply on
connection which did write/mkdir/rm/setperm etc. This causes deadlocks in real life, and I can't see a sane way of avoiding them: it is reasonable for someone to ignore watch notifications while doing other actions, and that means that we can do other writes. These writes can block pending other watchers; if one of these is the process blocked awaiting our ack, we deadlock. Signed-off-by: Rusty Russel <rusty@rustcorp.com.au> Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
Diffstat (limited to 'tools/xenstore/xenstored_transaction.c')
-rw-r--r--tools/xenstore/xenstored_transaction.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/tools/xenstore/xenstored_transaction.c b/tools/xenstore/xenstored_transaction.c
index afaef1bef2..eef4d29038 100644
--- a/tools/xenstore/xenstored_transaction.c
+++ b/tools/xenstore/xenstored_transaction.c
@@ -307,7 +307,6 @@ void do_transaction_end(struct connection *conn, const char *arg)
{
struct changed_node *i;
struct transaction *trans;
- bool fired = false;
if (!arg || (!streq(arg, "T") && !streq(arg, "F"))) {
send_error(conn, EINVAL);
@@ -337,12 +336,8 @@ void do_transaction_end(struct connection *conn, const char *arg)
/* Fire off the watches for everything that changed. */
list_for_each_entry(i, &trans->changes, list)
- fired |= fire_watches(conn, i->node, i->recurse);
+ fire_watches(conn, i->node, i->recurse);
}
-
- if (fired)
- conn->watch_ack = XS_TRANSACTION_END;
- else
- send_ack(conn, XS_TRANSACTION_END);
+ send_ack(conn, XS_TRANSACTION_END);
}