summaryrefslogtreecommitdiff
blob: ce9c654c565f43a1dbc1fde75c1f31630b31efbf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# HG changeset patch
# User Antoine Pitrou <solipsis@pitrou.net>
# Date 1375388712 -7200
# Node ID 0f17aed78168e63ec058c219d03cea7240f83dd6
# Parent  bb546f6d8ab4f513804d7a420657963881e5b447
Fix tkinter regression introduced by the security fix in #16248.

diff --git a/Lib/lib-tk/Tkinter.py b/Lib/lib-tk/Tkinter.py
--- a/Lib/lib-tk/Tkinter.py
+++ b/Lib/lib-tk/Tkinter.py
@@ -1736,7 +1736,7 @@ class Tk(Misc, Wm):
         # ensure that self.tk is always _something_.
         self.tk = None
         if baseName is None:
-            import sys, os
+            import os
             baseName = os.path.basename(sys.argv[0])
             baseName, ext = os.path.splitext(baseName)
             if ext not in ('.py', '.pyc', '.pyo'):