diff options
| author | Raimo Niskanen <raimo@erlang.org> | 2023-02-22 15:44:30 +0100 |
|---|---|---|
| committer | Raimo Niskanen <raimo@erlang.org> | 2023-02-27 10:04:14 +0100 |
| commit | 9113edaf9d60bcfabe2630e2d8f77a579ab93df2 (patch) | |
| tree | d1df1a3719afcbee7227ef8a24961c9c6a7d3458 /lib/reltool | |
| parent | b0afc29474f9625aa0b466b6672e0bbcefd07535 (diff) | |
| download | erlang-9113edaf9d60bcfabe2630e2d8f77a579ab93df2.tar.gz | |
Use `proc_lib:init_fail/2,3` where appropriate
Diffstat (limited to 'lib/reltool')
| -rw-r--r-- | lib/reltool/src/reltool.app.src | 6 | ||||
| -rw-r--r-- | lib/reltool/src/reltool_server.erl | 3 | ||||
| -rw-r--r-- | lib/reltool/src/reltool_sys_win.erl | 4 |
3 files changed, 8 insertions, 5 deletions
diff --git a/lib/reltool/src/reltool.app.src b/lib/reltool/src/reltool.app.src index fcefac3162..421ca01ea3 100644 --- a/lib/reltool/src/reltool.app.src +++ b/lib/reltool/src/reltool.app.src @@ -36,6 +36,8 @@ {registered, []}, {applications, [stdlib, kernel]}, {env, []}, - {runtime_dependencies, ["wx-@OTP-18350@","tools-2.6.14","stdlib-@OTP-18350@","sasl-@OTP-18350@", - "kernel-@OTP-18350@","erts-@OTP-18350@"]} + {runtime_dependencies, + ["wx-@OTP-18350@","tools-2.6.14", + "stdlib-@OTP-18490@","stdlib-@OTP-18350@","sasl-@OTP-18350@", + "kernel-@OTP-18350@","erts-@OTP-18350@"]} ]}. diff --git a/lib/reltool/src/reltool_server.erl b/lib/reltool/src/reltool_server.erl index 7027223fae..e14d171766 100644 --- a/lib/reltool/src/reltool_server.erl +++ b/lib/reltool/src/reltool_server.erl @@ -129,12 +129,13 @@ gen_spec(Pid) -> %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Server +-spec init(_) -> no_return(). init([{parent,Parent}|_] = Options) -> try do_init(Options) catch throw:{error,Reason} -> - proc_lib:init_ack(Parent,{error,Reason}); + proc_lib:init_fail(Parent,{error,Reason},{exit,normal}); error:Reason:Stacktrace -> exit({Reason, Stacktrace}) end. diff --git a/lib/reltool/src/reltool_sys_win.erl b/lib/reltool/src/reltool_sys_win.erl index e24f468f67..c8cf692647 100644 --- a/lib/reltool/src/reltool_sys_win.erl +++ b/lib/reltool/src/reltool_sys_win.erl @@ -183,7 +183,7 @@ do_init([{safe_config, Safe}, {parent, Parent} | Options]) -> restart_server_safe_config(true,Parent,Reason) -> io:format("~w(~w): <ERROR> ~tp\n", [?MODULE, ?LINE, Reason]), - proc_lib:init_ack(Parent, {error,Reason}); + proc_lib:init_fail(Parent, {error,Reason}, {exit,normal}); restart_server_safe_config(false,Parent,Reason) -> wx:new(), Strings = @@ -200,7 +200,7 @@ restart_server_safe_config(false,Parent,Reason) -> do_init([{safe_config,true},{parent,Parent},?safe_config]); ?wxID_CANCEL -> io:format("~w(~w): <ERROR> ~tp\n", [?MODULE, ?LINE, Reason]), - proc_lib:init_ack(Parent,{error,Reason}) + proc_lib:init_fail(Parent, {error,Reason}, {exit,normal}) end. exit_dialog([]) -> |
