summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Radestock <matthias@rabbitmq.com>2012-01-16 14:59:57 +0000
committerMatthias Radestock <matthias@rabbitmq.com>2012-01-16 14:59:57 +0000
commitb45e48ad5788cbb814fd46b7bec1f84a9261bc1d (patch)
tree54b6cc8d23834d7fb6b8b88b653f1fd132a0b2aa
parentbc83ba09747316d27a6ca6e359106d68bfc23550 (diff)
downloadrabbitmq-server-git-b45e48ad5788cbb814fd46b7bec1f84a9261bc1d.tar.gz
fix supervisor2 bug reported by dialyzer
The erroneous code is invoked when a child terminates normally at the same time as it is being terminated by the supervisor. So unsurprisingly we haven't seen this, and it's hard to test.
-rw-r--r--src/supervisor2.erl4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/supervisor2.erl b/src/supervisor2.erl
index f75da87221..26ea502ced 100644
--- a/src/supervisor2.erl
+++ b/src/supervisor2.erl
@@ -717,8 +717,8 @@ do_terminate(Child, SupName) when Child#child.pid =/= undefined ->
ok;
{error, normal} ->
case Child#child.restart_type of
- permanent -> ReportError(normal);
- {permanent, _Delay} -> ReportError(normal);
+ permanent -> ReportError(normal, Child);
+ {permanent, _Delay} -> ReportError(normal, Child);
_ -> ok
end;
{error, OtherReason} ->