Skip to content

Commit 9a6e575

Browse files
committed
list: fix typo in virsh patch
A last minute rename in commit fc122e1 to virsh.h was not properly reflected when rebasing virsh-pool.c in commit 93a346d. * tools/virsh-pool.c (vshStoragePoolListCollect): Use VSH_MATCH, not MATCH.
1 parent f299ddd commit 9a6e575

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

tools/virsh-pool.c

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -642,24 +642,24 @@ vshStoragePoolListCollect(vshControl *ctl,
642642
vshResetLibvirtError();
643643

644644
/* There is no way to get the pool type */
645-
if (MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_POOL_TYPE)) {
645+
if (VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_POOL_TYPE)) {
646646
vshError(ctl, "%s", _("Filtering using --type is not supported "
647647
"by this libvirt"));
648648
goto cleanup;
649649
}
650650

651651
/* Get the number of active pools */
652-
if (!MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_ACTIVE) ||
653-
MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_ACTIVE)) {
652+
if (!VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_ACTIVE) ||
653+
VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_ACTIVE)) {
654654
if ((nActivePools = virConnectNumOfStoragePools(ctl->conn)) < 0) {
655655
vshError(ctl, "%s", _("Failed to get the number of active pools "));
656656
goto cleanup;
657657
}
658658
}
659659

660660
/* Get the number of inactive pools */
661-
if (!MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_ACTIVE) ||
662-
MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_INACTIVE)) {
661+
if (!VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_ACTIVE) ||
662+
VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_INACTIVE)) {
663663
if ((nInactivePools = virConnectNumOfDefinedStoragePools(ctl->conn)) < 0) {
664664
vshError(ctl, "%s", _("Failed to get the number of inactive pools"));
665665
goto cleanup;
@@ -674,8 +674,8 @@ vshStoragePoolListCollect(vshControl *ctl,
674674
names = vshMalloc(ctl, sizeof(char *) * nAllPools);
675675

676676
/* Retrieve a list of active storage pool names */
677-
if (!MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_ACTIVE) ||
678-
MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_ACTIVE)) {
677+
if (!VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_ACTIVE) ||
678+
VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_ACTIVE)) {
679679
if (virConnectListStoragePools(ctl->conn,
680680
names, nActivePools) < 0) {
681681
vshError(ctl, "%s", _("Failed to list active pools"));
@@ -684,8 +684,8 @@ vshStoragePoolListCollect(vshControl *ctl,
684684
}
685685

686686
/* Add the inactive storage pools to the end of the name list */
687-
if (!MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_ACTIVE) ||
688-
MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_ACTIVE)) {
687+
if (!VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_ACTIVE) ||
688+
VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_ACTIVE)) {
689689
if (virConnectListDefinedStoragePools(ctl->conn,
690690
&names[nActivePools],
691691
nInactivePools) < 0) {
@@ -720,26 +720,26 @@ vshStoragePoolListCollect(vshControl *ctl,
720720
pool = list->pools[i];
721721

722722
/* persistence filter */
723-
if (MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_PERSISTENT)) {
723+
if (VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_PERSISTENT)) {
724724
if ((persistent = virStoragePoolIsPersistent(pool)) < 0) {
725725
vshError(ctl, "%s", _("Failed to get pool persistence info"));
726726
goto cleanup;
727727
}
728728

729-
if (!((MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_PERSISTENT) && persistent) ||
730-
(MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_TRANSIENT) && !persistent)))
729+
if (!((VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_PERSISTENT) && persistent) ||
730+
(VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_TRANSIENT) && !persistent)))
731731
goto remove_entry;
732732
}
733733

734734
/* autostart filter */
735-
if (MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_AUTOSTART)) {
735+
if (VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_AUTOSTART)) {
736736
if (virStoragePoolGetAutostart(pool, &autostart) < 0) {
737737
vshError(ctl, "%s", _("Failed to get pool autostart state"));
738738
goto cleanup;
739739
}
740740

741-
if (!((MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_AUTOSTART) && autostart) ||
742-
(MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_NO_AUTOSTART) && !autostart)))
741+
if (!((VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_AUTOSTART) && autostart) ||
742+
(VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_NO_AUTOSTART) && !autostart)))
743743
goto remove_entry;
744744
}
745745

0 commit comments

Comments
 (0)