webmcp
changeset 359:a74e62c96501
Bugfix in trace.error{}: close all open sections to show timings
author | jbe |
---|---|
date | Thu Mar 26 20:45:07 2015 +0100 (2015-03-26) |
parents | 545ec2e3eafa |
children | 785ff282af16 |
files | framework/env/trace/error.lua |
line diff
1.1 --- a/framework/env/trace/error.lua Thu Mar 26 20:19:54 2015 +0100 1.2 +++ b/framework/env/trace/error.lua Thu Mar 26 20:45:07 2015 +0100 1.3 @@ -9,8 +9,8 @@ 1.4 function trace.error(args) 1.5 if not trace._disabled then 1.6 trace._new_entry { type = "error" } 1.7 - local closed_section = trace._close_section() 1.8 - closed_section.hard_error = true -- TODO: not used, maybe remove 1.9 - trace._stack = { trace._tree } 1.10 + while #trace._stack > 1 do 1.11 + trace._close_section() 1.12 + end 1.13 end 1.14 end