[PATCH 2/7] util: Fix regression introduced by commit 4360a098441

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Which refactored the old code, and introduced new helper
virIsCapableVport, but the path for checking with access() is not
correctly constructed.
---
 src/util/virutil.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/util/virutil.c b/src/util/virutil.c
index 7773d5c..ebf902d 100644
--- a/src/util/virutil.c
+++ b/src/util/virutil.c
@@ -3163,7 +3163,7 @@ virIsCapableVport(const char *sysfs_prefix,
     int ret = -1;
 
     if (virAsprintf(&fc_host_path,
-                    "%shost%d%s",
+                    "%shost%d/%s",
                     sysfs_prefix ? sysfs_prefix : SYSFS_FC_HOST_PATH,
                     host,
                     "vport_create") < 0) {
@@ -3172,7 +3172,7 @@ virIsCapableVport(const char *sysfs_prefix,
     }
 
     if (virAsprintf(&scsi_host_path,
-                    "%shost%d%s",
+                    "%shost%d/%s",
                     sysfs_prefix ? sysfs_prefix : SYSFS_SCSI_HOST_PATH,
                     host,
                     "vport_create") < 0) {
-- 
1.8.1.4

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]