X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=test-tool%2Ftest-tool.c;h=73f3af5cf4de4d0b4c303a72f9d31ecd4a24865f;hb=9a8889e4d0c532b9f77af3a9cc7aae06adebfb83;hp=c1a3de7cee666f64d5c22fe1dfd1ece4e030b7d1;hpb=8869adf1e811d894088dbb0f371edc23299005c8;p=libguestfs.git diff --git a/test-tool/test-tool.c b/test-tool/test-tool.c index c1a3de7..73f3af5 100644 --- a/test-tool/test-tool.c +++ b/test-tool/test-tool.c @@ -100,11 +100,11 @@ main (int argc, char *argv[]) switch (c) { case 0: /* options which are long only */ - if (strcmp (long_options[option_index].name, "helper") == 0) + if (STREQ (long_options[option_index].name, "helper")) helper = optarg; - else if (strcmp (long_options[option_index].name, "qemu") == 0) + else if (STREQ (long_options[option_index].name, "qemu")) set_qemu (optarg, 0); - else if (strcmp (long_options[option_index].name, "qemudir") == 0) + else if (STREQ (long_options[option_index].name, "qemudir")) set_qemu (optarg, 1); else { fprintf (stderr, @@ -145,7 +145,7 @@ main (int argc, char *argv[]) /* Print out any environment variables which may relate to this test. */ for (i = 0; environ[i] != NULL; ++i) - if (strncmp (environ[i], "LIBGUESTFS_", 11) == 0) + if (STREQLEN (environ[i], "LIBGUESTFS_", 11)) printf ("%s\n", environ[i]); /* Create the handle and configure it. */