Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 59d9eda

Browse files
authored
Merge pull request #23058 from meeseeksmachine/auto-backport-of-pr-23051-on-v3.5.x
Backport PR #23051 on branch v3.5.x (Fix variable initialization due to jump bypassing it)
2 parents 7e29ce3 + 96e4a2e commit 59d9eda

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/_tkagg.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,7 @@ void load_tkinter_funcs(void)
259259
HANDLE process = GetCurrentProcess(); // Pseudo-handle, doesn't need closing.
260260
HMODULE* modules = NULL;
261261
DWORD size;
262+
bool tcl_ok = false, tk_ok = false;
262263
if (!EnumProcessModules(process, NULL, 0, &size)) {
263264
PyErr_SetFromWindowsErr(0);
264265
goto exit;
@@ -271,7 +272,6 @@ void load_tkinter_funcs(void)
271272
PyErr_SetFromWindowsErr(0);
272273
goto exit;
273274
}
274-
bool tcl_ok = false, tk_ok = false;
275275
for (unsigned i = 0; i < size / sizeof(HMODULE); ++i) {
276276
if (!tcl_ok) {
277277
tcl_ok = load_tcl(modules[i]);

0 commit comments

Comments
 (0)