summaryrefslogtreecommitdiff
path: root/usr/src/tools/onbld/Checks/ProcessCheck.py
diff options
context:
space:
mode:
authorJerry Jelinek <jerry.jelinek@joyent.com>2019-01-11 13:16:51 +0000
committerJerry Jelinek <jerry.jelinek@joyent.com>2019-01-11 13:16:51 +0000
commit882fee1ee6c160a1c4cb56a4874b0039ff1410c0 (patch)
treeadd61009c9f1e3c5849055eedf68b1ad9a8b7d97 /usr/src/tools/onbld/Checks/ProcessCheck.py
parentb7e394a4a3da3fcdb717314a5ebcd7a5f14def92 (diff)
parent247b7da039fd88350c50e3d7fef15bdab6bef215 (diff)
downloadillumos-joyent-882fee1ee6c160a1c4cb56a4874b0039ff1410c0.tar.gz
[illumos-gate merge]
commit 247b7da039fd88350c50e3d7fef15bdab6bef215 10205 Mounting zfs filesystems on startup shows incorrect data commit b928ac841f6012f92d5aedbd7dfacf443921fee3 10182 dd: print scaled stats commit c65ebfc7045424bd04a6c7719a27b0ad3399ad54 8886 mdns: update to mDNSResponder-878.1.1 commit 35786f6866ae52207d0f1a25fe7ca5f652f32ce0 9823 Deadlock in ACPI Method Evaluation 9824 Update ACPI to joyent/20180629 commit bc36eafdde0c7048471866fc7cea7b93852592db 9822 want iasl commit b75e7d76519aa3dc2e72aa357a039a6b65372a1c 9821 want a way to run vendor-specific commands via libscsi commit 2a613b5974ae49c8b068a3998ff554f8c6f0f593 9747 Implement CPU autoreplace based on Intel PPIN commit ca13eaa51ee900abba73dfb6624e492f7e48863e 9979 Support python3 for in-gate tools Conflicts: usr/src/uts/intel/sys/x86_archext.h usr/src/uts/i86pc/os/cmi_hw.c usr/src/tools/onbld/Checks/DbLookups.py usr/src/lib/fm/topo/modules/i86pc/chip/chip_subr.c
Diffstat (limited to 'usr/src/tools/onbld/Checks/ProcessCheck.py')
-rw-r--r--usr/src/tools/onbld/Checks/ProcessCheck.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/usr/src/tools/onbld/Checks/ProcessCheck.py b/usr/src/tools/onbld/Checks/ProcessCheck.py
index 52ebabd002..1d3bf9df07 100644
--- a/usr/src/tools/onbld/Checks/ProcessCheck.py
+++ b/usr/src/tools/onbld/Checks/ProcessCheck.py
@@ -23,8 +23,8 @@
# Copyright 2008 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
-# ident "%Z%%M% %I% %E% SMI"
-#
+
+# Copyright 2018 OmniOS Community Edition (OmniOSce) Association.
#
# Wrap a command-line check tool in a pythonic API
@@ -46,8 +46,8 @@ def processcheck(command, args, inpt, output):
# don't deadlock with the child if both pipes fill.
#
try:
- tmpfile = tempfile.TemporaryFile(prefix=command)
- except EnvironmentError, e:
+ tmpfile = tempfile.TemporaryFile(prefix=command, mode="w+b")
+ except EnvironmentError as e:
output.write("Could not create temporary file: %s\n" % e)
return (3, None)
@@ -55,7 +55,7 @@ def processcheck(command, args, inpt, output):
p = subprocess.Popen([command] + args,
stdin=subprocess.PIPE, stdout=tmpfile,
stderr=subprocess.STDOUT, close_fds=False)
- except OSError, e:
+ except OSError as e:
output.write("Could not execute %s: %s\n" % (command, e))
return (3, None)