forked from lix-project/lix
LocalStore initialization: Don't die if build-users-group doesn't exist
See NixOS/nixpkgs@9245516
This commit is contained in:
parent
bd0f362d2f
commit
3d97b8d1e7
|
@ -258,9 +258,9 @@ LocalStore::LocalStore(bool reserveSpace)
|
||||||
|
|
||||||
struct group * gr = getgrnam(settings.buildUsersGroup.c_str());
|
struct group * gr = getgrnam(settings.buildUsersGroup.c_str());
|
||||||
if (!gr)
|
if (!gr)
|
||||||
throw Error(format("the group ‘%1%’ specified in ‘build-users-group’ does not exist")
|
printMsg(lvlError, format("warning: the group ‘%1%’ specified in ‘build-users-group’ does not exist")
|
||||||
% settings.buildUsersGroup);
|
% settings.buildUsersGroup);
|
||||||
|
else {
|
||||||
struct stat st;
|
struct stat st;
|
||||||
if (stat(settings.nixStore.c_str(), &st))
|
if (stat(settings.nixStore.c_str(), &st))
|
||||||
throw SysError(format("getting attributes of path ‘%1%’") % settings.nixStore);
|
throw SysError(format("getting attributes of path ‘%1%’") % settings.nixStore);
|
||||||
|
@ -272,6 +272,7 @@ LocalStore::LocalStore(bool reserveSpace)
|
||||||
throw SysError(format("changing permissions on path ‘%1%’") % settings.nixStore);
|
throw SysError(format("changing permissions on path ‘%1%’") % settings.nixStore);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
checkStoreNotSymlink();
|
checkStoreNotSymlink();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue