1
0
mirror of https://gitlab.com/libvirt/libvirt.git synced 2025-03-07 17:28:15 +00:00

Adapt to VIR_STRDUP and VIR_STRNDUP in src/secret/*

This commit is contained in:
Michal Privoznik 2013-05-03 14:48:16 +02:00
parent a39875b7f8
commit 296d319f05

View File

@ -1097,9 +1097,8 @@ secretStateInitialize(bool privileged,
secretDriverLock(driverState); secretDriverLock(driverState);
if (privileged) { if (privileged) {
base = strdup(SYSCONFDIR "/libvirt"); if (VIR_STRDUP(base, SYSCONFDIR "/libvirt") < 0)
if (base == NULL) goto error;
goto out_of_memory;
} else { } else {
base = virGetUserConfigDirectory(); base = virGetUserConfigDirectory();
if (!base) if (!base)