[Python-checkins] python/dist/src/Modules posixmodule.c, 2.320, 2.321

loewis at users.sourceforge.net loewis at users.sourceforge.net
Tue Jun 15 14:50:03 EDT 2004


Update of /cvsroot/python/python/dist/src/Modules
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20488

Modified Files:
	posixmodule.c 
Log Message:
Return unicode strings from _getfullpathname even on W9X. Fixes #924703 .

Index: posixmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Modules/posixmodule.c,v
retrieving revision 2.320
retrieving revision 2.321
diff -C2 -d -r2.320 -r2.321
*** posixmodule.c	9 Jun 2004 01:46:02 -0000	2.320
--- posixmodule.c	15 Jun 2004 18:49:58 -0000	2.321
***************
*** 1737,1740 ****
--- 1737,1744 ----
  	                     outbuf, &temp))
  		return win32_error("GetFullPathName", inbuf);
+ 	if (PyUnicode_Check(PyTuple_GetItem(args, 0))) {
+ 		return PyUnicode_Decode(outbuf, strlen(outbuf),
+ 			Py_FileSystemDefaultEncoding, NULL);
+ 	}
  	return PyString_FromString(outbuf);
  } /* end of posix__getfullpathname */




More information about the Python-checkins mailing list