From: Fred Drake Date: Fri, 19 Mar 2004 15:22:36 +0000 (+0000) Subject: PyFile_WriteObject(): some of the local variables are only used when X-Git-Tag: v2.4a1~673 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=086a0f79cd56ce64062b599f4cb10b329ee33323;p=thirdparty%2FPython%2Fcpython.git PyFile_WriteObject(): some of the local variables are only used when Py_USING_UNICODE is defined --- diff --git a/Objects/fileobject.c b/Objects/fileobject.c index 05c9f4a9b257..1e8be6a39301 100644 --- a/Objects/fileobject.c +++ b/Objects/fileobject.c @@ -2005,8 +2005,10 @@ PyFile_WriteObject(PyObject *v, PyObject *f, int flags) } else if (PyFile_Check(f)) { FILE *fp = PyFile_AsFile(f); +#ifdef Py_USING_UNICODE PyObject *enc = ((PyFileObject*)f)->f_encoding; int result; +#endif if (fp == NULL) { err_closed(); return -1;