mirror of
https://github.com/python/cpython.git
synced 2025-12-11 03:20:01 +00:00
Patch #1232023: Don't include empty path component from registry,
so that the current directory does not get added to sys.path. Also fixes #1526785.
This commit is contained in:
parent
bda0dde1c4
commit
d22968af17
2 changed files with 7 additions and 0 deletions
|
|
@ -12,6 +12,9 @@ What's New in Python 2.5 release candidate 1?
|
||||||
Core and builtins
|
Core and builtins
|
||||||
-----------------
|
-----------------
|
||||||
|
|
||||||
|
- Patch #1232023: Stop including current directory in search
|
||||||
|
path on Windows.
|
||||||
|
|
||||||
- Fix some potential crashes found with failmalloc.
|
- Fix some potential crashes found with failmalloc.
|
||||||
|
|
||||||
- Fix warnings reported by Klocwork's static analysis tool.
|
- Fix warnings reported by Klocwork's static analysis tool.
|
||||||
|
|
|
||||||
|
|
@ -297,6 +297,10 @@ getpythonregpath(HKEY keyBase, int skipcore)
|
||||||
}
|
}
|
||||||
RegCloseKey(subKey);
|
RegCloseKey(subKey);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* return null if no path to return */
|
||||||
|
if (dataSize == 0) goto done;
|
||||||
|
|
||||||
/* original datasize from RegQueryInfo doesn't include the \0 */
|
/* original datasize from RegQueryInfo doesn't include the \0 */
|
||||||
dataBuf = malloc((dataSize+1) * sizeof(TCHAR));
|
dataBuf = malloc((dataSize+1) * sizeof(TCHAR));
|
||||||
if (dataBuf) {
|
if (dataBuf) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue