On Sun, Jan 18, 2009 at 11:42 AM, Andrew Ferguson
<address@hidden> wrote:
On Jan 18, 2009, at 12:36 PM, Andrew Ferguson wrote:
However,
>>> os.listdir("\\\\?\\c:\\Temp\\")
['dest', 'source', 'test', 'test-dest']
>>> os.listdir("\\\\?\\c:\\Temp")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
WindowsError: [Error 123] The filename, directory name, or volume label syntax is incorrect: '\\\\?\\c:\\Temp/*.*'
so, \\?\C:\Temp\ works, but \\?\C:\Temp fails. WTF?
And a followup, almost as a note, if we change to unicode, then it works...
>>> os.listdir("\\\\?\\c:\\Temp")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
WindowsError: [Error 123] The filename, directory name, or volume label syntax is incorrect: '\\\\?\\c:\\Temp/*.*'
>>> os.listdir(u"\\\\?\\c:\\Temp")
[u'dest', u'source', u'test', u'test-dest']
Gah.
Andrew