| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
TypeError where it previously crashed the interpreter. Patch by Brian Kearns
|
| |
|
|
|
|
|
|
| |
When converting REG_DWORD registry values into Python, the conversion
needs to be made from an *unsigned* long (k instead of i) to match the
DWORD type.
|
|
|
|
|
| |
This fixes a ValueError seen in winreg.SetValueEx when passed long
winreg.REG_DWORD values that should be supported by the underlying API.
|
|
|
|
| |
done in r81843 for py3k.
|
|
|
|
|
|
| |
ERROR_MORE_DATA, requiring another call to get the remaining data.
Patch by Daniel Stutzbach
|
| |
|
|
|
|
|
|
|
|
|
| |
*ReflectionKey functions used to not be documented or tested, but they are
now sufficiently documented and tested on platforms where they apply.
Additionally, fixed a bug in QueryReflectionKey which was returning an
incorrect value.
All tests pass from XP through Windows 7, on 32 and 64-bit platforms.
|
|
|
|
|
|
|
|
|
| |
since the introduction of the SETUP_WITH opcode,
__enter__ and __exit__ methods must belong to the type,
and are not retrieved at the instance level (__dict__ or __getattr__).
Add a note in whatsnew about this incompatibility;
old style classes are not affected.
|
| |
|
|
|
|
|
|
| |
("windows sprintf", different than swprintf)
Needed for the windows CE port.
|
|
|
|
|
|
|
| |
http://mail.python.org/pipermail/python-dev/2008-June/079988.html
Python 2.6 should stick with PyString_* in its codebase. The PyBytes_* names
in the spirit of 3.0 are available via a #define only. See the email thread.
|
| |
|
| |
|
|
|
|
|
| |
Adds _winreg.DisableReflectionKey, EnableReflectionKey, QueryReflectionKey,
KEY_WOW64_64KEY and KEY_WOW64_32KEY.
|
| |
|
|
|
|
| |
Added ExpandEnvironmentStrings to the _winreg module.
|
|
|
|
|
| |
backwards compatibility. Add Py_Refcnt, Py_Type, Py_Size, and
PyVarObject_HEAD_INIT.
|
|
|
|
| |
windows.h is included. Fixes warnings in PC builds.
|
|
|
|
| |
discovered using code analysis in VisualStudio 2005 Team Edition
|
| |
|
|
|
|
|
| |
in the returned string (logic error introduced by
recent patch).
|
| |
|
| |
|
| |
|
|
|
|
| |
Probably should be backported.
|
|
|
|
| |
in _winreg.c.
|
|
|
|
|
|
|
|
|
|
| |
isn't checked, and it *is* possible that a very large alloca() call is
made, e.g. when a large registry value is being read. I don't know if
alloca() in that case returns NULL or returns a pointer pointing outside
the stack, and I don't want to know -- I've simply replaced all calls to
alloca() with either PyMem_Malloc() or PyString_FromStringAndSize(NULL,)
as appropriate, followed by a size check. This addresses SF buf 851056.
Will backport to 2.3 next.
|
| |
|
|
|
|
|
|
|
| |
to a constant in the 'win32con' module, but this constant is also
defined in the _winreg module itself.
Bugfix candidate.
|
|
|
|
|
|
|
| |
comments everywhere that bugged me: /* Foo is inlined */ instead of
/* Inline Foo */. Somehow the "is inlined" phrase always confused me
for half a second (thinking, "No it isn't" until I added the missing
"here"). The new phrase is hopefully unambiguous.
|
| |
|
| |
|
| |
|
|
|
|
| |
object.
|
|
|
|
|
|
|
|
|
|
| |
comments, docstrings or error messages. I fixed two minor things in
test_winreg.py ("didn't" -> "Didn't" and "Didnt" -> "Didn't").
There is a minor style issue involved: Guido seems to have preferred English
grammar (behaviour, honour) in a couple places. This patch changes that to
American, which is the more prominent style in the source. I prefer English
myself, so if English is preferred, I'd be happy to supply a patch myself ;)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Trent Mick <trentm@activestate.com>:
Fix PC/msvcrtmodule.c and PC/winreg.c for Win64. Basically:
- sizeof(HKEY) > sizeof(long) on Win64, so use PyLong_FromVoidPtr()
instead of PyInt_FromLong() to return HKEY values on Win64
- Check for string overflow of an arbitrary registry value (I know
that ensuring that a registry value does not overflow 2**31 characters
seems ridiculous but it is *possible*).
Closes SourceForge patch #100517.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
errors in some of the hash algorithms. For exmaple, in float_hash and
complex_hash a certain part of the value is not included in the hash
calculation. See Tim's, Guido's, and my discussion of this on
python-dev in May under the title "fix float_hash and complex_hash for
64-bit *nix"
(2) The hash algorithms that use pointers (e.g. func_hash, code_hash)
are universally not correct on Win64 (they assume that sizeof(long) ==
sizeof(void*))
As well, this patch significantly cleans up the hash code. It adds the
two function _Py_HashDouble and _PyHash_VoidPtr that the various
hashing routine are changed to use.
These help maintain the hash function invariant: (a==b) =>
(hash(a)==hash(b))) I have added Lib/test/test_hash.py and
Lib/test/output/test_hash to test this for some cases.
|
|
|
|
| |
OO wrapper for this module.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
For more comments, read the patches@python.org archives.
For documentation read the comments in mymalloc.h and objimpl.h.
(This is not exactly what Vladimir posted to the patches list; I've
made a few changes, and Vladimir sent me a fix in private email for a
problem that only occurs in debug mode. I'm also holding back on his
change to main.c, which seems unnecessary to me.)
|
|
|