From f41e03c63f8c18ff7fec23b1f3e066e62cbcbefe Mon Sep 17 00:00:00 2001 From: Chunyan Liu Date: Thu, 10 Mar 2016 10:50:41 +0800 Subject: [PATCH] libxl_conf: reuse virDomainNetGetActualtype in libxlMakeNicList Reuse existing helper function virDomainNetGetActualtype. Signed-off-by: Chunyan Liu Signed-off-by: Jim Fehlig --- src/libxl/libxl_conf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libxl/libxl_conf.c b/src/libxl/libxl_conf.c index 93c943ba54..a4b2e21c06 100644 --- a/src/libxl/libxl_conf.c +++ b/src/libxl/libxl_conf.c @@ -1445,7 +1445,7 @@ libxlMakeNicList(virDomainDefPtr def, libxl_domain_config *d_config) return -1; for (i = 0; i < nnics; i++) { - if (l_nics[i]->type == VIR_DOMAIN_NET_TYPE_HOSTDEV) + if (virDomainNetGetActualType(l_nics[i]) == VIR_DOMAIN_NET_TYPE_HOSTDEV) continue; if (libxlMakeNic(def, l_nics[i], &x_nics[nvnics]))