diff options
author | Hans Bolinder <[email protected]> | 2018-02-07 16:20:18 +0100 |
---|---|---|
committer | Hans Bolinder <[email protected]> | 2018-02-07 16:20:18 +0100 |
commit | cd9b6371a13c37f8f82586fcd82f212d306d8fad (patch) | |
tree | e5108365606b25ccff0d977a9c82783af6e4aef7 /lib/common_test/src/ct_hooks.erl | |
parent | 3003f6150317cee3e2c6859a82829e1b2ff4f12e (diff) | |
parent | e2848c09db25b356fdddc4f5f9dd4da6e6cfb6ec (diff) | |
download | otp-cd9b6371a13c37f8f82586fcd82f212d306d8fad.tar.gz otp-cd9b6371a13c37f8f82586fcd82f212d306d8fad.tar.bz2 otp-cd9b6371a13c37f8f82586fcd82f212d306d8fad.zip |
Merge branch 'hasse/no_get_stacktrace/OTP-14861'
* hasse/no_get_stacktrace/OTP-14861:
erts: Update abstract format doc with stacktrace variable
wx: Do not call erlang:get_stacktrace()
tools: Do not call erlang:get_stacktrace()
stdlib: Do not call erlang:get_stacktrace()
sasl: Do not call erlang:get_stacktrace()
runtime_tools: Do not call erlang:get_stacktrace()
reltool: Do not call erlang:get_stacktrace()
parsetools: Do not call erlang:get_stacktrace()
observer: Do not call erlang:get_stacktrace()
mnesia: Do not call erlang:get_stacktrace() (cont)
mnesia: Do not call erlang:get_stacktrace()
kernel: Do not call erlang:get_stacktrace()
inets: Do not call erlang:get_stacktrace()
eunit: Do not call erlang:get_stacktrace()
et: Do not call erlang:get_stacktrace()
dialyzer: Do not call erlang:get_stacktrace()
debugger: Do not call erlang:get_stacktrace()
debugger: Do not try to restore stacktrace
common_test: Do not call erlang:get_stacktrace()
Diffstat (limited to 'lib/common_test/src/ct_hooks.erl')
-rw-r--r-- | lib/common_test/src/ct_hooks.erl | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/common_test/src/ct_hooks.erl b/lib/common_test/src/ct_hooks.erl index f0592a40be..bb33f0243b 100644 --- a/lib/common_test/src/ct_hooks.erl +++ b/lib/common_test/src/ct_hooks.erl @@ -233,8 +233,7 @@ call([{Hook, call_id, NextFun} | Rest], Config, Meta, Hooks) -> Rest ++ [{NewId, call_init}, {NewId,NextFun}]} end, call(resort(NewRest,NewHooks,Meta), Config, Meta, NewHooks) - catch Error:Reason -> - Trace = erlang:get_stacktrace(), + catch Error:Reason:Trace -> ct_logs:log("Suite Hook","Failed to start a CTH: ~tp:~tp", [Error,{Reason,Trace}]), call([], {fail,"Failed to start CTH" @@ -422,8 +421,7 @@ catch_apply(M,F,A, Default, Fallback) -> catch_apply(M,F,A) -> try erlang:apply(M,F,A) - catch _:Reason -> - Trace = erlang:get_stacktrace(), + catch _:Reason:Trace -> ct_logs:log("Suite Hook","Call to CTH failed: ~w:~tp", [error,{Reason,Trace}]), throw({error_in_cth_call, |