mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-23 06:05:27 +00:00
virConfSetValue: Simplify condition
There's no need for condition of the following form: if (str && STREQ(str, dst)) since we have STREQ_NULLABLE macro that handles NULL cases. Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
d85dcae4b2
commit
4523b7769d
@ -884,7 +884,7 @@ virConfSetValue(virConfPtr conf,
|
||||
|
||||
cur = conf->entries;
|
||||
while (cur != NULL) {
|
||||
if ((cur->name != NULL) && (STREQ(cur->name, setting)))
|
||||
if (STREQ_NULLABLE(cur->name, setting))
|
||||
break;
|
||||
prev = cur;
|
||||
cur = cur->next;
|
||||
|
Loading…
Reference in New Issue
Block a user