util.debug: Add +1 to level when getting locals table, to account for current function
authorMatthew Wild <mwild1@gmail.com>
Sat, 28 Apr 2012 16:21:19 +0100
changeset 4778 127de6eec433
parent 4777 74ae0433f8dd
child 4780 4b8f2b91826c
util.debug: Add +1 to level when getting locals table, to account for current function
util/debug.lua
--- a/util/debug.lua	Sat Apr 28 16:20:26 2012 +0100
+++ b/util/debug.lua	Sat Apr 28 16:21:19 2012 +0100
@@ -97,7 +97,7 @@
 		levels[(level-start_level)+1] = {
 			level = level;
 			info = info;
-			locals = get_locals_table(level);
+			locals = get_locals_table(level+1);
 			upvalues = get_upvalues_table(info.func);
 		};
 	end