diff options
| author | Simon MacMullen <simon@rabbitmq.com> | 2012-08-17 17:02:40 +0100 |
|---|---|---|
| committer | Simon MacMullen <simon@rabbitmq.com> | 2012-08-17 17:02:40 +0100 |
| commit | aa899051e6492dff8a5f743b4689daf885f58669 (patch) | |
| tree | 6160596e78c2c55a29f57f907205dba82bd615ac | |
| parent | 7a47cd858fa15d3d665e0c078de9efc5941790b7 (diff) | |
| download | rabbitmq-server-git-aa899051e6492dff8a5f743b4689daf885f58669.tar.gz | |
I was thinking that which_applications needed to come first so that the
process would be gone by the time we got to is_process_alive. But if we swap
them round the which_applications check will return false in the shutdown case
anyway. And of course is_process_alive/1 is rather faster.
| -rw-r--r-- | src/rabbit_mirror_queue_misc.erl | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rabbit_mirror_queue_misc.erl b/src/rabbit_mirror_queue_misc.erl index 8c12067017..7d1efd505a 100644 --- a/src/rabbit_mirror_queue_misc.erl +++ b/src/rabbit_mirror_queue_misc.erl @@ -110,8 +110,8 @@ is_really_alive(Pid) -> end. is_really_alive0(Pid) -> - lists:keymember(rabbit, 1, application:which_applications(infinity)) - andalso is_process_alive(Pid). + is_process_alive(Pid) andalso + lists:keymember(rabbit, 1, application:which_applications(infinity)). on_node_up() -> Qs = |
