render / rpms / libvirt

Forked from rpms/libvirt 9 months ago
Clone
7a3408
From 2fdb0fe7911b41f3578072431da1b65e9d499c49 Mon Sep 17 00:00:00 2001
7a3408
Message-Id: <2fdb0fe7911b41f3578072431da1b65e9d499c49@dist-git>
7a3408
From: Matthias Bolte <matthias.bolte@googlemail.com>
7a3408
Date: Tue, 8 Sep 2015 09:52:57 +0200
7a3408
Subject: [PATCH] vmx: Some whitespace cleanup
7a3408
7a3408
https://bugzilla.redhat.com/show_bug.cgi?id=1172544
7a3408
7a3408
(cherry picked from commit 1d204cf19617b87f0bddfb0d9855ee99d7f5d2ae)
7a3408
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
7a3408
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
7a3408
---
7a3408
 src/vmx/vmx.c | 25 +++++++++++++------------
7a3408
 1 file changed, 13 insertions(+), 12 deletions(-)
7a3408
7a3408
diff --git a/src/vmx/vmx.c b/src/vmx/vmx.c
7a3408
index e77de62..3b23c0d 100644
7a3408
--- a/src/vmx/vmx.c
7a3408
+++ b/src/vmx/vmx.c
7a3408
@@ -2,7 +2,7 @@
7a3408
  * vmx.c: VMware VMX parsing/formatting functions
7a3408
  *
7a3408
  * Copyright (C) 2010-2014 Red Hat, Inc.
7a3408
- * Copyright (C) 2009-2010 Matthias Bolte <matthias.bolte@googlemail.com>
7a3408
+ * Copyright (C) 2009-2011, 2014-2015 Matthias Bolte <matthias.bolte@googlemail.com>
7a3408
  *
7a3408
  * This library is free software; you can redistribute it and/or
7a3408
  * modify it under the terms of the GNU Lesser General Public
7a3408
@@ -2189,8 +2189,8 @@ virVMXParseDisk(virVMXContext *ctx, virDomainXMLOptionPtr xmlopt, virConfPtr con
7a3408
             virReportError(VIR_ERR_INTERNAL_ERROR,
7a3408
                            _("Invalid or not yet handled value '%s' "
7a3408
                              "for VMX entry '%s' for device type '%s'"),
7a3408
-                             fileName, fileName_name,
7a3408
-                             deviceType ? deviceType : "unknown");
7a3408
+                           fileName, fileName_name,
7a3408
+                           deviceType ? deviceType : "unknown");
7a3408
             goto cleanup;
7a3408
         }
7a3408
     } else if (device == VIR_DOMAIN_DISK_DEVICE_CDROM) {
7a3408
@@ -2246,8 +2246,8 @@ virVMXParseDisk(virVMXContext *ctx, virDomainXMLOptionPtr xmlopt, virConfPtr con
7a3408
             virReportError(VIR_ERR_INTERNAL_ERROR,
7a3408
                            _("Invalid or not yet handled value '%s' "
7a3408
                              "for VMX entry '%s' for device type '%s'"),
7a3408
-                             fileName, fileName_name,
7a3408
-                             deviceType ? deviceType : "unknown");
7a3408
+                           fileName, fileName_name,
7a3408
+                           deviceType ? deviceType : "unknown");
7a3408
             goto cleanup;
7a3408
         }
7a3408
     } else if (device == VIR_DOMAIN_DISK_DEVICE_FLOPPY) {
7a3408
@@ -2270,8 +2270,8 @@ virVMXParseDisk(virVMXContext *ctx, virDomainXMLOptionPtr xmlopt, virConfPtr con
7a3408
             virReportError(VIR_ERR_INTERNAL_ERROR,
7a3408
                            _("Invalid or not yet handled value '%s' "
7a3408
                              "for VMX entry '%s' for device type '%s'"),
7a3408
-                             fileName, fileName_name,
7a3408
-                             deviceType ? deviceType : "unknown");
7a3408
+                           fileName, fileName_name,
7a3408
+                           deviceType ? deviceType : "unknown");
7a3408
             goto cleanup;
7a3408
         }
7a3408
     } else {
7a3408
@@ -2543,8 +2543,8 @@ virVMXParseEthernet(virConfPtr conf, int controller, virDomainNetDefPtr *def)
7a3408
             STRCASENEQ(virtualDev, "e1000e")) {
7a3408
             virReportError(VIR_ERR_INTERNAL_ERROR,
7a3408
                            _("Expecting VMX entry '%s' to be 'vlance' or 'vmxnet' or "
7a3408
-                             "'vmxnet3' or 'e1000e' or 'e1000e' but found '%s'"), virtualDev_name,
7a3408
-                           virtualDev);
7a3408
+                             "'vmxnet3' or 'e1000e' or 'e1000e' but found '%s'"),
7a3408
+                           virtualDev_name, virtualDev);
7a3408
             goto cleanup;
7a3408
         }
7a3408
 
7a3408
@@ -3358,7 +3358,7 @@ virVMXFormatVNC(virDomainGraphicsDefPtr def, virBufferPtr buffer)
7a3408
 
7a3408
 int
7a3408
 virVMXFormatDisk(virVMXContext *ctx, virDomainDiskDefPtr def,
7a3408
-                     virBufferPtr buffer)
7a3408
+                 virBufferPtr buffer)
7a3408
 {
7a3408
     int controllerOrBus, unit;
7a3408
     const char *vmxDeviceType = NULL;
7a3408
@@ -3374,7 +3374,7 @@ virVMXFormatDisk(virVMXContext *ctx, virDomainDiskDefPtr def,
7a3408
      * an ISO.
7a3408
      */
7a3408
     const char *fileExt = (def->device == VIR_DOMAIN_DISK_DEVICE_DISK) ?
7a3408
-                            ".vmdk" : ".iso";
7a3408
+                           ".vmdk" : ".iso";
7a3408
 
7a3408
     /* Check that we got a valid device type */
7a3408
     if (def->device != VIR_DOMAIN_DISK_DEVICE_DISK &&
7a3408
@@ -3417,7 +3417,7 @@ virVMXFormatDisk(virVMXContext *ctx, virDomainDiskDefPtr def,
7a3408
     if (def->device == VIR_DOMAIN_DISK_DEVICE_DISK &&
7a3408
         type == VIR_STORAGE_TYPE_FILE) {
7a3408
         vmxDeviceType = (def->bus == VIR_DOMAIN_DISK_BUS_SCSI) ?
7a3408
-            "scsi-hardDisk" : "ata-hardDisk";
7a3408
+                        "scsi-hardDisk" : "ata-hardDisk";
7a3408
     } else if (def->device == VIR_DOMAIN_DISK_DEVICE_CDROM) {
7a3408
         if (type == VIR_STORAGE_TYPE_FILE)
7a3408
             vmxDeviceType = "cdrom-image";
7a3408
@@ -3489,6 +3489,7 @@ virVMXFormatDisk(virVMXContext *ctx, virDomainDiskDefPtr def,
7a3408
         virBufferAsprintf(buffer,
7a3408
                           "%s%d:%d.mode = \"independent-nonpersistent\"\n",
7a3408
                           busType, controllerOrBus, unit);
7a3408
+
7a3408
     return 0;
7a3408
 }
7a3408
 
7a3408
-- 
7a3408
2.5.2
7a3408