Skip to content

Commit 06a0ca9

Browse files
authored
Merge pull request #752 from basho/hotfix/ku/message-queue-len-2.1
Avoid extra work requesting info not needed - develop
2 parents e4b76bc + 1a86659 commit 06a0ca9

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/riak_repl_util.erl

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -826,12 +826,11 @@ safe_pid_to_list(NotAPid) ->
826826
NotAPid.
827827

828828
safe_get_msg_q_len(Pid) when is_pid(Pid) ->
829-
ProcInfo = erlang:process_info(Pid),
830-
proplists:get_value(message_queue_len, ProcInfo);
829+
{message_queue_len, Len} = erlang:process_info(Pid, message_queue_len),
830+
Len;
831831
safe_get_msg_q_len(Other) ->
832832
Other.
833833

834-
835834
peername(Socket, Transport) ->
836835
case Transport:peername(Socket) of
837836
{ok, {Ip, Port}} ->

0 commit comments

Comments
 (0)