about summary refs log tree commit diff
path: root/src/libutil/util.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2019-05-03T08·44+0200
committerEelco Dolstra <edolstra@gmail.com>2019-05-03T08·48+0200
commitf9a2ea44867cd1dbb408bca4df0ced806137b7f7 (patch)
treef0dcb7d07f3006fbebd7ea0ce30a7783423bd329 /src/libutil/util.cc
parent989cb3777753024072160776ea37348689b89d44 (diff)
Fix "Bad system call" running i686-linux binaries on x86_64-linux
To determine which seccomp filters to install, we were incorrectly
using settings.thisSystem, which doesn't denote the actual system when
--system is used.

Fixes #2791.
Diffstat (limited to 'src/libutil/util.cc')
-rw-r--r--src/libutil/util.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/libutil/util.cc b/src/libutil/util.cc
index e3dcd246c681..a7170566533e 100644
--- a/src/libutil/util.cc
+++ b/src/libutil/util.cc
@@ -38,6 +38,9 @@ extern char * * environ;
 namespace nix {
 
 
+const std::string nativeSystem = SYSTEM;
+
+
 BaseError & BaseError::addPrefix(const FormatOrString & fs)
 {
     prefix_ = fs.s + prefix_;