nix-store --serve: Don't loop forever

nix-store --export takes a tmproot, which can only release by exiting.
Substituters don't currently work in a way that could take advantage of
the looping, anyway.

Signed-off-by: Shea Levy <shea@shealevy.com>
This commit is contained in:
Shea Levy 2014-02-07 14:07:31 -05:00
parent 3a38d0f356
commit 9488447594

View file

@ -260,7 +260,7 @@ string StoreAPI::makeValidityRegistration(const PathSet & paths,
void StoreAPI::serve(Source & in, Sink & out, bool sign)
{
for (string cmd = readString(in); !cmd.empty(); cmd = readString(in)) {
string cmd = readString(in);
if (cmd == "query") {
for (cmd = readString(in); !cmd.empty(); cmd = readString(in)) {
PathSet paths = readStrings<PathSet>(in);
@ -286,7 +286,6 @@ void StoreAPI::serve(Source & in, Sink & out, bool sign)
else
throw Error(format("Unknown serve command `%1%'") % cmd);
}
}
ValidPathInfo decodeValidPathInfo(std::istream & str, bool hashGiven)