diff options
| author | Simon MacMullen <simon@rabbitmq.com> | 2011-11-07 12:42:55 +0000 |
|---|---|---|
| committer | Simon MacMullen <simon@rabbitmq.com> | 2011-11-07 12:42:55 +0000 |
| commit | cc9747ed9b514debc212a380eaee769c4711dee2 (patch) | |
| tree | 440a5c3dea890c8a45a8eaeca8568ca86ff0016d /src | |
| parent | 42dbab810891e59c6396c5b8b85ba1f8a327c5ff (diff) | |
| download | rabbitmq-server-git-cc9747ed9b514debc212a380eaee769c4711dee2.tar.gz | |
Cosmetic
Diffstat (limited to 'src')
| -rw-r--r-- | src/supervisor2.erl | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/src/supervisor2.erl b/src/supervisor2.erl index b9c824144d..f75da87221 100644 --- a/src/supervisor2.erl +++ b/src/supervisor2.erl @@ -695,21 +695,19 @@ child_res(#child{restart_type={permanent,_}},normal, false) -> {error, normal}; child_res(#child{}, normal, false) -> ok; child_res(#child{}, R, _) -> {error, R}. -timeout_start(#child{shutdown = Time}, TimeoutMsg) - when is_integer(Time) -> - erlang:send_after(Time, self(), TimeoutMsg); -timeout_start(#child{}, _TimeoutMsg) -> +timeout_start(#child{shutdown = Time}, Msg) when is_integer(Time) -> + erlang:send_after(Time, self(), Msg); +timeout_start(#child{}, _Msg) -> ok. -timeout_stop(#child{shutdown = Time}, TRef, TimeoutMsg, false) - when is_integer(Time) -> +timeout_stop(#child{shutdown = Time}, TRef, Msg, false) when is_integer(Time) -> erlang:cancel_timer(TRef), receive - TimeoutMsg -> ok + Msg -> ok after 0 -> ok end; -timeout_stop(#child{}, ok, _TimeoutMsg, _Timedout) -> +timeout_stop(#child{}, ok, _Msg, _Timedout) -> ok. do_terminate(Child, SupName) when Child#child.pid =/= undefined -> |
