mini-os: Fix xenbus_switch_state's transaction retry

When xenbus_switch_state has to retry the transaction which it just
created, it needs to recreate another one.  Clearing xbt triggers it.

Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
This commit is contained in:
Keir Fraser committed 2010-04-07 08:17:21 +01:00
1 parent 15d5739ea9
commit cdabe14bff
1 file changed
+3 -1
+3 -1
View File
@@ -154,8 +154,10 @@ char *xenbus_switch_state(xenbus_transaction_t xbt, const char* path, XenbusStat
msg = xenbus_write(xbt, path, value);
exit:
if (xbt_flag)
if (xbt_flag) {
msg2 = xenbus_transaction_end(xbt, 0, &retry);
xbt = XBT_NIL;
}
if (msg == NULL && msg2 != NULL)
msg = msg2;
} while (retry);
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.