From ed55ba92a7bc969494c9772601fcc5a0569ea009 Mon Sep 17 00:00:00 2001 From: Neal Norwitz Date: Tue, 12 Nov 2002 23:10:31 +0000 Subject: [PATCH] SF # 627900, Bytecode copy bug in freeze Pass co_freevars and co_cellvars to new.code(). --- Tools/freeze/modulefinder.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Tools/freeze/modulefinder.py b/Tools/freeze/modulefinder.py index 924c3a4aa363..ca09508679c1 100644 --- a/Tools/freeze/modulefinder.py +++ b/Tools/freeze/modulefinder.py @@ -434,7 +434,8 @@ class ModuleFinder: return new.code(co.co_argcount, co.co_nlocals, co.co_stacksize, co.co_flags, co.co_code, tuple(consts), co.co_names, co.co_varnames, new_filename, co.co_name, - co.co_firstlineno, co.co_lnotab) + co.co_firstlineno, co.co_lnotab, + co.co_freevars, co.co_cellvars) def test(): -- 2.47.3