From dc8fb257341163e41c31797a3cdd3625cdd89b30 Mon Sep 17 00:00:00 2001 From: Marc Hartmayer Date: Wed, 30 Nov 2016 12:47:02 +0100 Subject: [PATCH] conf: virDomainDriveAddressIsUsedByDisk: Rename type to bus_type Comparing the parameter 'type' against the member 'bus' instead of against the member 'type' is quite confusing. Rename the parameter 'type' to 'bus_type' to clarify its meaning. Signed-off-by: Marc Hartmayer Reviewed-by: Boris Fiuczynski --- src/conf/domain_conf.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 89408e766b..25d7186aca 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -4019,7 +4019,7 @@ virDomainDefPostParseGraphics(virDomainDef *def) /** * virDomainDriveAddressIsUsedByDisk: * @def: domain definition containing the disks to check - * @type: bus type + * @bus_type: bus type * @addr: address to check for duplicates * * Return true if any disk is already using the given address on the @@ -4027,7 +4027,7 @@ virDomainDefPostParseGraphics(virDomainDef *def) */ static bool virDomainDriveAddressIsUsedByDisk(const virDomainDef *def, - virDomainDiskBus type, + virDomainDiskBus bus_type, const virDomainDeviceDriveAddress *addr) { virDomainDiskDefPtr disk; @@ -4036,7 +4036,7 @@ virDomainDriveAddressIsUsedByDisk(const virDomainDef *def, for (i = 0; i < def->ndisks; i++) { disk = def->disks[i]; - if (disk->bus != type || + if (disk->bus != bus_type || disk->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_DRIVE) continue; -- 2.47.2