[Python-checkins] r78788 - in python/trunk: Doc/library/subprocess.rst Lib/subprocess.py
florent.xicluna
python-checkins at python.org
Mon Mar 8 11:58:12 CET 2010
Author: florent.xicluna
Date: Mon Mar 8 11:58:12 2010
New Revision: 78788
Log:
Fix syntax: "rc != None" -> "rc is not None"
Modified:
python/trunk/Doc/library/subprocess.rst
python/trunk/Lib/subprocess.py
Modified: python/trunk/Doc/library/subprocess.rst
==============================================================================
--- python/trunk/Doc/library/subprocess.rst (original)
+++ python/trunk/Doc/library/subprocess.rst Mon Mar 8 11:58:12 2010
@@ -541,7 +541,7 @@
pipe = os.popen("cmd", 'w')
...
rc = pipe.close()
- if rc != None and rc % 256:
+ if rc is not None and rc % 256:
print "There were some errors"
==>
process = Popen("cmd", 'w', shell=True, stdin=PIPE)
Modified: python/trunk/Lib/subprocess.py
==============================================================================
--- python/trunk/Lib/subprocess.py (original)
+++ python/trunk/Lib/subprocess.py Mon Mar 8 11:58:12 2010
@@ -349,7 +349,7 @@
pipe = os.popen("cmd", 'w')
...
rc = pipe.close()
-if rc != None and rc % 256:
+if rc is not None and rc % 256:
print "There were some errors"
==>
process = Popen("cmd", 'w', shell=True, stdin=PIPE)
More information about the Python-checkins
mailing list