[issue45616] Python Launcher Matches 3.10 instead of 3.1
Yu Liu
report at bugs.python.org
Tue Oct 26 21:13:19 EDT 2021
Yu Liu <yuliu2016> added the comment:
Had a quick look at the launcher file. Maybe something like this?
diff --git a/PC/launcher.c b/PC/launcher.c
index fbfb49a..a965a9d 100644
--- a/PC/launcher.c
+++ b/PC/launcher.c
@@ -542,7 +542,7 @@ find_python_by_version(wchar_t const * wanted_ver)
}
for (i = 0; i < num_installed_pythons; i++, ip++) {
n = wcslen(ip->version);
- if (n > wlen)
+ if (n != wlen)
n = wlen;
if ((wcsncmp(ip->version, wanted_ver, n) == 0) &&
/* bits == 0 => don't care */
----------
nosy: +yuliu2016
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue45616>
_______________________________________
More information about the Python-bugs-list
mailing list