Kaydet (Commit) d22968af authored tarafından Martin v. Löwis's avatar Martin v. Löwis

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.
üst bda0dde1
......@@ -12,6 +12,9 @@ What's New in Python 2.5 release candidate 1?
Core and builtins
-----------------
- Patch #1232023: Stop including current directory in search
path on Windows.
- Fix some potential crashes found with failmalloc.
- Fix warnings reported by Klocwork's static analysis tool.
......
......@@ -297,6 +297,10 @@ getpythonregpath(HKEY keyBase, int skipcore)
}
RegCloseKey(subKey);
}
/* return null if no path to return */
if (dataSize == 0) goto done;
/* original datasize from RegQueryInfo doesn't include the \0 */
dataBuf = malloc((dataSize+1) * sizeof(TCHAR));
if (dataBuf) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment