Commit a3b5fd2 1 parent 92c8d63 commit a3b5fd2 Copy full SHA for a3b5fd2
File tree 2 files changed +11
-6
lines changed
2 files changed +11
-6
lines changed Original file line number Diff line number Diff line change @@ -487,17 +487,21 @@ def stack_table
487
487
def frame_table
488
488
funcs = @stack_table_hash [ :frame_table ] . fetch ( :func )
489
489
lines = @stack_table_hash [ :frame_table ] . fetch ( :line )
490
- size = funcs . length
490
+ raise unless lines . size == funcs . size
491
+
492
+ size = funcs . size
491
493
none = [ nil ] * size
492
- categories = @frame_categories . map ( &:idx )
494
+ default = [ 0 ] * size
495
+ unidentified = [ -1 ] * size
493
496
494
- raise unless lines . size == funcs . size
497
+ categories = @frame_categories . map ( &:idx )
498
+ subcategories = @frame_subcategories
495
499
496
500
{
497
- address : [ - 1 ] * size ,
498
- inlineDepth : [ 0 ] * size ,
501
+ address : unidentified ,
502
+ inlineDepth : default ,
499
503
category : categories ,
500
- subcategory : nil ,
504
+ subcategory : subcategories ,
501
505
func : funcs ,
502
506
nativeSymbol : none ,
503
507
innerWindowID : none ,
Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ def assert_valid_firefox_profile(profile)
62
62
assert_equal frame_length , thread [ "frameTable" ] [ "innerWindowID" ] . length
63
63
assert_equal frame_length , thread [ "frameTable" ] [ "func" ] . length
64
64
assert_equal frame_length , thread [ "frameTable" ] [ "category" ] . length
65
+ assert_equal frame_length , thread [ "frameTable" ] [ "subcategory" ] . length
65
66
assert_equal frame_length , thread [ "frameTable" ] [ "inlineDepth" ] . length
66
67
assert_equal frame_length , thread [ "frameTable" ] [ "address" ] . length
67
68
You can’t perform that action at this time.
0 commit comments