From cc087c398941302629ac6fd140639e65a9516cb8 Mon Sep 17 00:00:00 2001 From: Henrik Nord Date: Mon, 29 Aug 2011 15:57:54 +0200 Subject: [cover]fix leftover {'DOWN', ..} msg in callers queue After stopping cover with cover:stop() there could still be a {'DOWN',...} leftover message in the calling process's message queue. This unexpected leftover could be eliminated if erlang:demonitor/2 with option flush would be used in certain points --- lib/tools/src/cover.erl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/tools/src') diff --git a/lib/tools/src/cover.erl b/lib/tools/src/cover.erl index fb9744d759..e21bd1b88c 100644 --- a/lib/tools/src/cover.erl +++ b/lib/tools/src/cover.erl @@ -522,7 +522,7 @@ call(Request) -> {?SERVER,Reply} -> Reply end, - erlang:demonitor(Ref), + erlang:demonitor(Ref, [flush]), Return end. @@ -545,7 +545,7 @@ remote_call(Node,Request) -> {?SERVER,Reply} -> Reply end, - erlang:demonitor(Ref), + erlang:demonitor(Ref, [flush]), Return end. -- cgit v1.2.3