[Python-bugs-list] [ python-Bugs-672132 ] registry functions don't handle null characters

SourceForge.net noreply@sourceforge.net
Tue, 21 Jan 2003 15:09:39 -0800


Bugs item #672132, was opened at 2003-01-22 10:09
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=672132&group_id=5470

Category: Windows
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Mark Hammond (mhammond)
Assigned to: Mark Hammond (mhammond)
Summary: registry functions don't handle null characters

Initial Comment:
As determined via
http://mail.python.org/pipermail/python-win32/2003-January/000745.html

Registry *value names* (not just the data values) can
contain embedded NULL characters, and indeed appear to
be Unicode - ie, WinNT registry uses Unicode natively,
and the value names are MBCS encoded in the "A" API
version of these functions.

_winreg.EnumValue, _winreg.EnumKey (and the same in the
win32api module) are affected.

I wonder if a fix to this should actually return
Unicode objects if a high-byte exists?  At the very
least, we must use the "length" of the valuename
returned, rather than assuming null termination.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=672132&group_id=5470