mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-03 17:47:15 +03:00
nwfilter: Remove unprivileged code path to set base
Commit id f8ab364c removed ability to run this driver unprivileged. Coverity detected the check and flagged it.
This commit is contained in:
parent
d507b97185
commit
aafe41971c
@ -219,14 +219,8 @@ nwfilterDriverStartup(bool privileged ATTRIBUTE_UNUSED,
|
|||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (privileged) {
|
if ((base = strdup(SYSCONFDIR "/libvirt")) == NULL)
|
||||||
if ((base = strdup(SYSCONFDIR "/libvirt")) == NULL)
|
goto out_of_memory;
|
||||||
goto out_of_memory;
|
|
||||||
} else {
|
|
||||||
base = virGetUserConfigDirectory();
|
|
||||||
if (!base)
|
|
||||||
goto error;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (virAsprintf(&driverState->configDir,
|
if (virAsprintf(&driverState->configDir,
|
||||||
"%s/nwfilter", base) == -1)
|
"%s/nwfilter", base) == -1)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user