[Python-checkins] r68825 - python/branches/io-c/Python/pythonrun.c

antoine.pitrou python-checkins at python.org
Tue Jan 20 23:38:29 CET 2009


Author: antoine.pitrou
Date: Tue Jan 20 23:38:29 2009
New Revision: 68825

Log:
FileIO.name is just a plain attribute, we can set it directly



Modified:
   python/branches/io-c/Python/pythonrun.c

Modified: python/branches/io-c/Python/pythonrun.c
==============================================================================
--- python/branches/io-c/Python/pythonrun.c	(original)
+++ python/branches/io-c/Python/pythonrun.c	Tue Jan 20 23:38:29 2009
@@ -764,7 +764,7 @@
 	}
 
 	text = PyUnicode_FromString(name);
-	if (text == NULL || PyObject_SetAttrString(raw, "_name", text) < 0)
+	if (text == NULL || PyObject_SetAttrString(raw, "name", text) < 0)
 		goto error;
 	res = PyObject_CallMethod(raw, "isatty", "");
 	if (res == NULL)


More information about the Python-checkins mailing list