summary refs log tree commit diff stats
path: root/qemu-nbd.c
diff options
context:
space:
mode:
authorAnthony Liguori <aliguori@us.ibm.com>2012-11-14 08:51:06 -0600
committerAnthony Liguori <aliguori@us.ibm.com>2012-11-14 08:51:06 -0600
commitde148eb79c7894178a1c2da6f2320b9ce6b0daee (patch)
tree6bca41970bb4b8f83aaee4e02559086838a5cbb6 /qemu-nbd.c
parent5f580e9411a24b7decc07013edeb8abf8d5ae25c (diff)
parentc8969eded252058e90e91f12f75f32aceae46ec9 (diff)
downloadfocaccia-qemu-de148eb79c7894178a1c2da6f2320b9ce6b0daee.tar.gz
focaccia-qemu-de148eb79c7894178a1c2da6f2320b9ce6b0daee.zip
Merge remote-tracking branch 'bonzini/nbd-next' into staging
* bonzini/nbd-next:
  nbd: fixes to read-only handling
  hmp: add NBD server commands
  nbd: disallow nbd-server-add before nbd-server-start
  nbd: force read-only export for read-only devices
  nbd: fix nbd_server_stop crash when no server was running
  nbd: accept URIs
  nbd: accept relative path to Unix socket
  qemu-nbd: initialize main loop before block layer

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'qemu-nbd.c')
-rw-r--r--qemu-nbd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/qemu-nbd.c b/qemu-nbd.c
index 15bcd08123..80f08d8464 100644
--- a/qemu-nbd.c
+++ b/qemu-nbd.c
@@ -539,6 +539,7 @@ int main(int argc, char **argv)
         snprintf(sockpath, 128, SOCKET_PATH, basename(device));
     }
 
+    qemu_init_main_loop();
     bdrv_init();
     atexit(bdrv_close_all);
 
@@ -584,7 +585,6 @@ int main(int argc, char **argv)
         memset(&client_thread, 0, sizeof(client_thread));
     }
 
-    qemu_init_main_loop();
     qemu_set_fd_handler2(fd, nbd_can_accept, nbd_accept, NULL,
                          (void *)(uintptr_t)fd);