]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/libvirt.git/commitdiff
virsh: Fix the typos
authorOsier Yang <jyang@redhat.com>
Tue, 11 Sep 2012 10:48:19 +0000 (18:48 +0800)
committerOsier Yang <jyang@redhat.com>
Tue, 11 Sep 2012 10:50:12 +0000 (18:50 +0800)
* tools/virsh-network.c: s/MATCH/VSH_MATCH/

tools/virsh-network.c

index f6623ff500a4b3e001253bc60660eaa641edd3f4..5c3daa3d209256b46d0cbbb96558362b5bd7a5fc 100644 (file)
@@ -434,8 +434,8 @@ fallback:
     vshResetLibvirtError();
 
     /* Get the number of active networks */
-    if (!MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_ACTIVE) ||
-        MATCH(VIR_CONNECT_LIST_NETWORKS_ACTIVE)) {
+    if (!VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_ACTIVE) ||
+        VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_ACTIVE)) {
         if ((nActiveNets = virConnectNumOfNetworks(ctl->conn)) < 0) {
             vshError(ctl, "%s", _("Failed to get the number of active networks"));
             goto cleanup;
@@ -443,8 +443,8 @@ fallback:
     }
 
     /* Get the number of inactive networks */
-    if (!MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_ACTIVE) ||
-        MATCH(VIR_CONNECT_LIST_NETWORKS_INACTIVE)) {
+    if (!VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_ACTIVE) ||
+        VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_INACTIVE)) {
         if ((nInactiveNets = virConnectNumOfDefinedNetworks(ctl->conn)) < 0) {
             vshError(ctl, "%s", _("Failed to get the number of inactive networks"));
             goto cleanup;
@@ -459,8 +459,8 @@ fallback:
     names = vshMalloc(ctl, sizeof(char *) * nAllNets);
 
     /* Retrieve a list of active network names */
-    if (!MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_ACTIVE) ||
-        MATCH(VIR_CONNECT_LIST_NETWORKS_ACTIVE)) {
+    if (!VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_ACTIVE) ||
+        VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_ACTIVE)) {
         if (virConnectListNetworks(ctl->conn,
                                    names, nActiveNets) < 0) {
             vshError(ctl, "%s", _("Failed to list active networks"));
@@ -469,8 +469,8 @@ fallback:
     }
 
     /* Add the inactive networks to the end of the name list */
-    if (!MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_ACTIVE) ||
-        MATCH(VIR_CONNECT_LIST_NETWORKS_ACTIVE)) {
+    if (!VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_ACTIVE) ||
+        VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_ACTIVE)) {
         if (virConnectListDefinedNetworks(ctl->conn,
                                           &names[nActiveNets],
                                           nInactiveNets) < 0) {
@@ -505,26 +505,26 @@ filter:
         net = list->nets[i];
 
         /* persistence filter */
-        if (MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_PERSISTENT)) {
+        if (VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_PERSISTENT)) {
             if ((persistent = virNetworkIsPersistent(net)) < 0) {
                 vshError(ctl, "%s", _("Failed to get network persistence info"));
                 goto cleanup;
             }
 
-            if (!((MATCH(VIR_CONNECT_LIST_NETWORKS_PERSISTENT) && persistent) ||
-                  (MATCH(VIR_CONNECT_LIST_NETWORKS_TRANSIENT) && !persistent)))
+            if (!((VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_PERSISTENT) && persistent) ||
+                  (VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_TRANSIENT) && !persistent)))
                 goto remove_entry;
         }
 
         /* autostart filter */
-        if (MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_AUTOSTART)) {
+        if (VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_FILTERS_AUTOSTART)) {
             if (virNetworkGetAutostart(net, &autostart) < 0) {
                 vshError(ctl, "%s", _("Failed to get network autostart state"));
                 goto cleanup;
             }
 
-            if (!((MATCH(VIR_CONNECT_LIST_NETWORKS_AUTOSTART) && autostart) ||
-                  (MATCH(VIR_CONNECT_LIST_NETWORKS_NO_AUTOSTART) && !autostart)))
+            if (!((VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_AUTOSTART) && autostart) ||
+                  (VSH_MATCH(VIR_CONNECT_LIST_NETWORKS_NO_AUTOSTART) && !autostart)))
                 goto remove_entry;
         }
         /* the pool matched all filters, it may stay */