This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author hannukoo
Recipients
Date 2003-10-05.10:50:30
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Behaviour tested in Python 2.3 (final) and 2.3.2 (final).
os.listdir('') and os.listdir(u'') have very different
behaviour across different OSes:

WinXP/WinNT:
os.listdir('') -- current dir (e.g. c:\\python)
os.listdir(u'') -- root dir (e.g. c:\\)

Win98
os.listdir('') -- root dir
os.listdir(u'') -- root dir

Redhat Linux 9.0
os.listdir('') -- OSError
os.listdir(u'') -- OSError

Particularly weird is the WinXP/WinNT behaviour that is
different between unicode and normal strings.

Suggestion for fix: Make os.listdir for empty strings 
always
raise an exception or always list the current working 
directory.
History
Date User Action Args
2007-08-23 14:17:31adminlinkissue818059 messages
2007-08-23 14:17:31admincreate