Respect return value from nbd_client()
authorJes Sorensen <Jes.Sorensen@redhat.com>
Tue, 31 Aug 2010 07:30:34 +0000 (09:30 +0200)
committerBlue Swirl <blauwirbel@gmail.com>
Sat, 4 Sep 2010 09:45:51 +0000 (09:45 +0000)
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
qemu-nbd.c

index 9cc8f472e6f1e8fcab7532b45e0dba406e0bea4d..67ce50b62bdf3ae059c564b3c47584b430044013 100644 (file)
@@ -417,7 +417,10 @@ int main(int argc, char **argv)
 
             show_parts(device);
 
-            nbd_client(fd);
+            ret = nbd_client(fd);
+            if (ret) {
+                ret = 1;
+            }
             close(fd);
  out:
             kill(pid, SIGTERM);