diff options
author | Chun-wei Fan <fanchunwei@src.gnome.org> | 2017-06-15 09:03:38 +0800 |
---|---|---|
committer | Chun-wei Fan <fanchunwei@src.gnome.org> | 2017-06-15 16:02:07 +0800 |
commit | e8f39a0a2408898e8a36e9011705c7a55f115afc (patch) | |
tree | 0be3dbef84888e7cb46c4a2c64fa97f18979d8ee /giscanner/utils.py | |
parent | f3561115e44cceebc9aecb859ffdfca4ef36cf93 (diff) | |
download | gobject-introspection-e8f39a0a2408898e8a36e9011705c7a55f115afc.tar.gz |
giscanner/utils.py: Fix on non-UNIX-like platforms
Commit 85b1d70b93211415d975deff6050f1401743e72d changed the null device
from the platform-independent os.devnull to the UNIX /dev/null, which
broke introspection builds on non-UNIX-like platforms, as /dev/null is a
notion that does not exist on those platforms. Fix this by changing
back to os.devnull, but still opening it as writable.
https://bugzilla.gnome.org/show_bug.cgi?id=781312
Diffstat (limited to 'giscanner/utils.py')
-rw-r--r-- | giscanner/utils.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/giscanner/utils.py b/giscanner/utils.py index da848d52..df512d7b 100644 --- a/giscanner/utils.py +++ b/giscanner/utils.py @@ -159,7 +159,7 @@ def get_libtool_command(options): libtool_cmd = 'glibtool' try: subprocess.check_call([libtool_cmd, '--version'], - stdout=open('/dev/null', 'w')) + stdout=open(os.devnull, 'w')) except (subprocess.CalledProcessError, OSError): # If libtool's not installed, assume we don't need it return None |