diff options
author | Siri Hansen <siri@erlang.org> | 2011-11-10 12:07:31 +0100 |
---|---|---|
committer | Siri Hansen <siri@erlang.org> | 2011-11-10 12:07:31 +0100 |
commit | 2df8e1f2ba502530e23081ee3b4644c577d8c99f (patch) | |
tree | 418e812be3e94251175b4e8946e28aaab2fd6ff9 /lib | |
parent | 49d53261a5372a1d8c0b9954fae4e2c0d6100fd4 (diff) | |
parent | 01f80e8454e03a14f63152eb5f2d2696a4ec824d (diff) | |
download | otp-2df8e1f2ba502530e23081ee3b4644c577d8c99f.tar.gz otp-2df8e1f2ba502530e23081ee3b4644c577d8c99f.tar.bz2 otp-2df8e1f2ba502530e23081ee3b4644c577d8c99f.zip |
Merge branch 'siri/stdlib/badarg-extract-child/OTP-9669'
* siri/stdlib/badarg-extract-child/OTP-9669:
Handle undefined pid when reporting error from supervisor
Diffstat (limited to 'lib')
-rw-r--r-- | lib/stdlib/src/supervisor.erl | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/stdlib/src/supervisor.erl b/lib/stdlib/src/supervisor.erl index f20ea18fd0..2dd5ccce7a 100644 --- a/lib/stdlib/src/supervisor.erl +++ b/lib/stdlib/src/supervisor.erl @@ -1238,15 +1238,15 @@ report_error(Error, Reason, Child, SupName) -> error_logger:error_report(supervisor_report, ErrorMsg). -extract_child(Child) when is_pid(Child#child.pid) -> - [{pid, Child#child.pid}, +extract_child(Child) when is_list(Child#child.pid) -> + [{nb_children, length(Child#child.pid)}, {name, Child#child.name}, {mfargs, Child#child.mfargs}, {restart_type, Child#child.restart_type}, {shutdown, Child#child.shutdown}, {child_type, Child#child.child_type}]; extract_child(Child) -> - [{nb_children, length(Child#child.pid)}, + [{pid, Child#child.pid}, {name, Child#child.name}, {mfargs, Child#child.mfargs}, {restart_type, Child#child.restart_type}, |