[PATCH 3/6] util: perf: Adhere to coding style of error checks in virPerfEventEnable

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

 



---
 src/util/virperf.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/util/virperf.c b/src/util/virperf.c
index 0ae4744..bd65587 100644
--- a/src/util/virperf.c
+++ b/src/util/virperf.c
@@ -186,7 +186,7 @@ virPerfEventEnable(virPerfPtr perf,

     switch (type) {
     case VIR_PERF_EVENT_CMT:
-        if (virPerfCmtEnable(event, pid))
+        if (virPerfCmtEnable(event, pid) < 0)
             return -1;
         break;
     case VIR_PERF_EVENT_LAST:
-- 
2.8.1

--
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]