From: Peter Krempa Date: Thu, 6 May 2021 14:22:41 +0000 (+0200) Subject: conf: domain: Don't initialize virTristateBool local variables used for virXMLPropTri... X-Git-Tag: v7.4.0-rc1~189 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f66d7461d4be75a7f41b6e1da14f760143012677;p=thirdparty%2Flibvirt.git conf: domain: Don't initialize virTristateBool local variables used for virXMLPropTristateBool virXMLPropTristateBool already initializes the value to VIR_TRISTATE_BOOL_ABSENT so we no longer need to do that for certain local variables. Signed-off-by: Peter Krempa Reviewed-by: Michal Privoznik --- diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 2bc2e55ee4..ea99a4c40a 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -12569,7 +12569,7 @@ virDomainGraphicsDefParseXMLSDL(virDomainGraphicsDef *def, { VIR_XPATH_NODE_AUTORESTORE(ctxt) xmlNodePtr glNode; - virTristateBool fullscreen = VIR_TRISTATE_BOOL_NO; + virTristateBool fullscreen; ctxt->node = node; @@ -12640,7 +12640,7 @@ static int virDomainGraphicsDefParseXMLDesktop(virDomainGraphicsDef *def, xmlNodePtr node) { - virTristateBool fullscreen = VIR_TRISTATE_BOOL_NO; + virTristateBool fullscreen; if (virXMLPropTristateBool(node, "fullscreen", VIR_XML_PROP_NONE, &fullscreen) < 0) @@ -12662,7 +12662,7 @@ virDomainGraphicsDefParseXMLSpice(virDomainGraphicsDef *def, g_autofree xmlNodePtr *node_list = NULL; int n = 0; size_t i = 0; - virTristateBool autoport = VIR_TRISTATE_BOOL_NO; + virTristateBool autoport; xmlNodePtr cur; VIR_XPATH_NODE_AUTORESTORE(ctxt)