about summary refs log tree commit diff
path: root/src/libstore/build.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2019-06-17T06·08+0200
committerEelco Dolstra <edolstra@gmail.com>2019-06-17T06·08+0200
commit3cc1125595d97b4ab7369e37e4ad22f4cfecb8b2 (patch)
tree4d82b71a91dbb27dee52f12babc4dc77592cdacf /src/libstore/build.cc
parent2743bf0bb1727056ce6d6d6be4e38c3251aac1f8 (diff)
Another attempt at getting pseudoterminals to work on macOS
Diffstat (limited to 'src/libstore/build.cc')
-rw-r--r--src/libstore/build.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/libstore/build.cc b/src/libstore/build.cc
index cccf0c7c687b..5b38bcf3c5ec 100644
--- a/src/libstore/build.cc
+++ b/src/libstore/build.cc
@@ -2196,6 +2196,9 @@ void DerivationGoal::startBuilder()
 
         if (chown(slaveName.c_str(), buildUser->getUID(), 0))
             throw SysError("changing owner of pseudoterminal slave");
+    } else {
+        if (grantpt(builderOut.readSide.get()))
+            throw SysError("granting access to pseudoterminal slave");
     }
 
     #if 0