From: Cole Robinson Date: Fri, 10 Jul 2009 01:50:20 +0000 (-0400) Subject: storage: disk: Fix parthelper '-g' option handling. X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=a3711708f782190ebb00bd22461316beaaef762b;p=libvirt.git storage: disk: Fix parthelper '-g' option handling. Typo was breaking 'parthelper -g', preventing disk pool definition. --- diff --git a/src/parthelper.c b/src/parthelper.c index f456cccb89..5df46e8d23 100644 --- a/src/parthelper.c +++ b/src/parthelper.c @@ -36,7 +36,7 @@ #include /* we don't need to include the full internal.h just for this */ -#define STRNEQ(a,b) (strcmp((a),(b)) != 0) +#define STREQ(a,b) (strcmp((a),(b)) == 0) /* Make the comparisons below fail if your parted headers are so old that they lack the definition. */ @@ -56,7 +56,7 @@ int main(int argc, char **argv) PedPartition *part; int cmd = DISK_LAYOUT; - if (argc == 3 && STRNEQ(argv[2], "-g")) { + if (argc == 3 && STREQ(argv[2], "-g")) { cmd = DISK_GEOMETRY; } else if (argc != 2) { fprintf(stderr, "syntax: %s DEVICE [-g]\n", argv[0]);