[Python-checkins] r53814 - sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py
phillip.eby
python-checkins at python.org
Sat Feb 17 18:55:44 CET 2007
Author: phillip.eby
Date: Sat Feb 17 18:55:43 2007
New Revision: 53814
Modified:
sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py
Log:
Fix error if script contains null byte. (backport from trunk)
Modified: sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py
==============================================================================
--- sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py (original)
+++ sandbox/branches/setuptools-0.6/setuptools/command/easy_install.py Sat Feb 17 18:55:43 2007
@@ -1460,7 +1460,7 @@
"Is this string a valid Python script?"
try:
compile(text, filename, 'exec')
- except SyntaxError:
+ except (SyntaxError, TypeError):
return False
else:
return True
More information about the Python-checkins
mailing list