File tree Expand file tree Collapse file tree 2 files changed +5
-9
lines changed Expand file tree Collapse file tree 2 files changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -214,12 +214,8 @@ parse_command_line_tests(ParsedArgs) ->
214214 % % this is a little ugly, the process that creates the ets table to store
215215 % % the tracing state cannot shutdown or the table will be gc'ed, so create
216216 % % a dummy proc that doens't die
217- proc_lib :spawn (
218- fun () ->
219- rt_redbug :new (),
220- rt_redbug :set_tracing_applied (proplists :is_defined (apply_traces , ParsedArgs )),
221- timer :sleep (infinity )
222- end ),
217+ rt_redbug :new (),
218+ rt_redbug :set_tracing_applied (proplists :is_defined (apply_traces , ParsedArgs )),
223219 % % Parse Command Line Tests
224220 {CodePaths , SpecificTests } =
225221 lists :foldl (fun extract_test_names /2 ,
Original file line number Diff line number Diff line change 3333
3434% % Create a new ets to store globally whether we're tracing or not.
3535new () ->
36- rt_trace_tab = ets : new ( rt_trace_tab , [ named_table ]) .
36+ ok .
3737
3838set_tracing_applied (TracingApplied ) when is_boolean (TracingApplied ) ->
3939 lager :info (" Setting apply tracing to ~p " , [TracingApplied ]),
40- ets : insert ( rt_trace_tab , { apply_traces ,TracingApplied } ).
40+ rt_config : set ( apply_traces , TracingApplied ).
4141
4242is_tracing_applied () ->
43- ( catch ets : lookup_element ( rt_trace_tab , apply_traces , 2 )) == true .
43+ rt_config : get ( apply_traces ) .
4444
4545% % Apply traces to one or more nodes using redbug tracing and syntax.
4646% %
You can’t perform that action at this time.
0 commit comments