[Python-checkins] r85515 - in python/branches/py3k: Include/fileutils.h Python/fileutils.c

victor.stinner python-checkins at python.org
Fri Oct 15 13:15:55 CEST 2010


Author: victor.stinner
Date: Fri Oct 15 13:15:54 2010
New Revision: 85515

Log:
Mark _Py_char2wchar() input argument as constant


Modified:
   python/branches/py3k/Include/fileutils.h
   python/branches/py3k/Python/fileutils.c

Modified: python/branches/py3k/Include/fileutils.h
==============================================================================
--- python/branches/py3k/Include/fileutils.h	(original)
+++ python/branches/py3k/Include/fileutils.h	Fri Oct 15 13:15:54 2010
@@ -6,7 +6,7 @@
 #endif
 
 PyAPI_FUNC(wchar_t *) _Py_char2wchar(
-    char *arg);
+    const char *arg);
 
 PyAPI_FUNC(char*) _Py_wchar2char(
     const wchar_t *text);

Modified: python/branches/py3k/Python/fileutils.c
==============================================================================
--- python/branches/py3k/Python/fileutils.c	(original)
+++ python/branches/py3k/Python/fileutils.c	Fri Oct 15 13:15:54 2010
@@ -17,7 +17,7 @@
    PyMem_Free() to free the memory), or NULL on error (conversion error or
    memory error). */
 wchar_t*
-_Py_char2wchar(char* arg)
+_Py_char2wchar(const char* arg)
 {
     wchar_t *res;
 #ifdef HAVE_BROKEN_MBSTOWCS


More information about the Python-checkins mailing list