summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bitbake/lib/bb/build.py3
-rw-r--r--bitbake/lib/bb/runqueue.py2
2 files changed, 2 insertions, 3 deletions
diff --git a/bitbake/lib/bb/build.py b/bitbake/lib/bb/build.py
index 4f8ac9573b..44ad3965a2 100644
--- a/bitbake/lib/bb/build.py
+++ b/bitbake/lib/bb/build.py
@@ -38,8 +38,7 @@ from bb import data, event, mkdirhier, utils
38bblogger = logging.getLogger('BitBake') 38bblogger = logging.getLogger('BitBake')
39logger = logging.getLogger('BitBake.Build') 39logger = logging.getLogger('BitBake.Build')
40 40
41NULL = open('/dev/null', 'r') 41NULL = open(os.devnull, 'r+')
42
43 42
44# When we execute a python function we'd like certain things 43# When we execute a python function we'd like certain things
45# in all namespaces, hence we add them to __builtins__ 44# in all namespaces, hence we add them to __builtins__
diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py
index d4cea7d5d4..ee7cfe7d61 100644
--- a/bitbake/lib/bb/runqueue.py
+++ b/bitbake/lib/bb/runqueue.py
@@ -1140,7 +1140,7 @@ class RunQueueExecute:
1140 # Make the child the process group leader 1140 # Make the child the process group leader
1141 os.setpgid(0, 0) 1141 os.setpgid(0, 0)
1142 # No stdin 1142 # No stdin
1143 newsi = os.open('/dev/null', os.O_RDWR) 1143 newsi = os.open(os.devnull, os.O_RDWR)
1144 os.dup2(newsi, sys.stdin.fileno()) 1144 os.dup2(newsi, sys.stdin.fileno())
1145 # Stdout to a logfile 1145 # Stdout to a logfile
1146 #logout = data.expand("${TMPDIR}/log/stdout.%s" % os.getpid(), self.cfgData, True) 1146 #logout = data.expand("${TMPDIR}/log/stdout.%s" % os.getpid(), self.cfgData, True)