From: Ján Tomko Date: Mon, 18 May 2020 13:23:46 +0000 (+0200) Subject: qemu: only return two values in virQEMUDriverConfigLoadMemoryEntry X-Git-Tag: v6.4.0-rc1~29 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d265171b5784657dccb5215d28a72b213553db0a;p=thirdparty%2Flibvirt.git qemu: only return two values in virQEMUDriverConfigLoadMemoryEntry The intention of these split Load*Entry functions is to prevent virQEMUDriverConfigLoadFile from getting too large. There's no need to signal to the caller whether an entry was found or not, only whether there was an error. Remove the non-standard return 1. Signed-off-by: Ján Tomko Reviewed-by: Daniel Henrique Barboza --- diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c index 2d4e2a46f3..b49299e1de 100644 --- a/src/qemu/qemu_conf.c +++ b/src/qemu/qemu_conf.c @@ -977,7 +977,7 @@ virQEMUDriverConfigLoadMemoryEntry(virQEMUDriverConfigPtr cfg, } else if (rc > 0) { VIR_FREE(cfg->memoryBackingDir); cfg->memoryBackingDir = g_strdup_printf("%s/libvirt/qemu", dir); - return 1; + return 0; } return 0;