On 1/15/19 8:23 AM, Ján Tomko wrote: > Split out parts of the config parsing code to make > the parent function easier to read. > > Signed-off-by: Ján Tomko <jtomko@xxxxxxxxxx> > --- > src/qemu/qemu_conf.c | 38 +++++++++++++++++++++++--------------- > 1 file changed, 23 insertions(+), 15 deletions(-) > > diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c > index b5024705d8..d3f266e338 100644 > --- a/src/qemu/qemu_conf.c > +++ b/src/qemu/qemu_conf.c > @@ -423,6 +423,28 @@ virQEMUDriverConfigHugeTLBFSInit(virHugeTLBFSPtr hugetlbfs, > } > > > +static int > +virQEMUDriverConfigLoadSPICEEntry(virQEMUDriverConfigPtr cfg, > + virConfPtr conf) > +{ > + if (virConfGetValueBool(conf, "spice_tls", &cfg->spiceTLS) < 0) > + return -1; > + if (virConfGetValueString(conf, "spice_tls_x509_cert_dir", &cfg->spiceTLSx509certdir) < 0) > + return -1; > + if (virConfGetValueBool(conf, "spice_sasl", &cfg->spiceSASL) < 0) > + return -1; > + if (virConfGetValueString(conf, "spice_sasl_dir", &cfg->spiceSASLdir) < 0) > + return -1; > + if (virConfGetValueString(conf, "spice_listen", &cfg->spiceListen) < 0) > + return -1; > + if (virConfGetValueString(conf, "spice_password", &cfg->spicePassword) < 0) > + return -1; > + if (virConfGetValueBool(conf, "spice_auto_unix_socket", &cfg->spiceAutoUnixSocket) < 0) > + return -1; > + > + return 0; > +} > + blank line Reviewed-by: John Ferlan <jferlan@xxxxxxxxxx> John -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list