]> xenbits.xensource.com Git - xen.git/commitdiff
Fix xenstore-client.c compile
authorKeir Fraser <keir.fraser@citrix.com>
Thu, 1 May 2008 15:37:28 +0000 (16:37 +0100)
committerKeir Fraser <keir.fraser@citrix.com>
Thu, 1 May 2008 15:37:28 +0000 (16:37 +0100)
errx() is not necessarily defined as a never-returns function. Fix
lookup_mode() to account for this.

Signed-off-by: John Levon <john.levon@sun.com>
tools/xenstore/xenstore_client.c

index 762a014c263c74c3aae70b09b55a70db39d6b6fb..aca23ed4c4bee86a473c5016f2145a4a8420f902 100644 (file)
@@ -450,8 +450,9 @@ static enum mode lookup_mode(const char *m)
        return MODE_write;
     else if (strcmp(m, "read") == 0)
        return MODE_read;
-    else
-       errx(1, "unknown mode %s\n", m);
+
+    errx(1, "unknown mode %s\n", m);
+    return 0;
 }
 
 int