about summary refs log tree commit diff
path: root/src/build-remote/build-remote.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2017-05-02T10·16+0200
committerEelco Dolstra <edolstra@gmail.com>2017-05-02T10·16+0200
commit174b68a2a2e9e58fa1a1a0036858a566c51684dc (patch)
treefb8af58549562a1c697474e7ea95e2ad80224747 /src/build-remote/build-remote.cc
parent70581b63633016329789872c73dc48b1d498c729 (diff)
build-hook: If there are no machines defined, quit permanently
Diffstat (limited to 'src/build-remote/build-remote.cc')
-rw-r--r--src/build-remote/build-remote.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/build-remote/build-remote.cc b/src/build-remote/build-remote.cc
index acf571ff15..388f1e0468 100644
--- a/src/build-remote/build-remote.cc
+++ b/src/build-remote/build-remote.cc
@@ -150,6 +150,11 @@ int main (int argc, char * * argv)
         auto machines = readConf();
         debug("got %d remote builders", machines.size());
 
+        if (machines.empty()) {
+            std::cerr << "# decline-permanently\n";
+            return;
+        }
+
         string drvPath;
         string storeUri;
         for (string line; getline(cin, line);) {