diff options
author | Jan Alexander Steffens (heftig) <jsteffens@make.tv> | 2019-11-11 12:41:23 +0100 |
---|---|---|
committer | Jan Alexander Steffens (heftig) <jsteffens@make.tv> | 2019-11-11 12:41:44 +0100 |
commit | 49fea2520f5c672493a91be8c0e3bb4ef6de6e27 (patch) | |
tree | 0a87f7903ce4f986880e0f34d76c16f1449a64aa /scripts | |
parent | 2e6bd1ca8d4e09fa7c5f5c8a39ce110d6e9f290c (diff) | |
download | gstreamer-49fea2520f5c672493a91be8c0e3bb4ef6de6e27.tar.gz |
python: Avoid using 'is' to compare strings
This is the wrong operator to use, which only seems to work because
`os.name` and `'nt'` happen to be the same object. Python 3.8 also
produces a `SyntaxWarning` when encountering this pattern.
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/common.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/common.py b/scripts/common.py index 4fea527359..f9c19850d2 100644 --- a/scripts/common.py +++ b/scripts/common.py @@ -11,7 +11,7 @@ import uuid ROOTDIR = os.path.abspath(os.path.dirname(__file__)) -if os.name is 'nt': +if os.name == 'nt': import ctypes from ctypes import wintypes _GetShortPathNameW = ctypes.windll.kernel32.GetShortPathNameW |