]> xenbits.xensource.com Git - libvirt.git/commitdiff
freebsd: Avoid /bin/true in commandtest
authorMatthias Bolte <matthias.bolte@googlemail.com>
Thu, 28 Jul 2011 15:51:26 +0000 (17:51 +0200)
committerMatthias Bolte <matthias.bolte@googlemail.com>
Fri, 29 Jul 2011 10:12:58 +0000 (12:12 +0200)
Rely on PATH and use just true, because on FreeBSD it's /usr/bin/true.

tests/commanddata/test16.log
tests/commandtest.c

index 2433a4d74ee1204d23a5ae5d2d6ad9352d7d6712..70881650a61d8433c0f88808dcaddb929c798d4c 100644 (file)
@@ -1 +1 @@
-A=B /bin/true C
+A=B true C
index 2e800ae879dba27a8bc37fc8aa8935c967c34337..9ba53b8e131b8a891b17f2a85e9a1377fe6958ca 100644 (file)
@@ -566,9 +566,9 @@ cleanup:
  */
 static int test16(const void *unused ATTRIBUTE_UNUSED)
 {
-    virCommandPtr cmd = virCommandNew("/bin/true");
+    virCommandPtr cmd = virCommandNew("true");
     char *outactual = NULL;
-    const char *outexpect = "A=B /bin/true C";
+    const char *outexpect = "A=B true C";
     int ret = -1;
     int fd = -1;
 
@@ -610,7 +610,7 @@ cleanup:
  */
 static int test17(const void *unused ATTRIBUTE_UNUSED)
 {
-    virCommandPtr cmd = virCommandNew("/bin/true");
+    virCommandPtr cmd = virCommandNew("true");
     int ret = -1;
     char *outbuf;
     char *errbuf;