aboutsummaryrefslogtreecommitdiffstats
path: root/lib/tools/src/cover.erl
diff options
context:
space:
mode:
authorHenrik Nord <[email protected]>2011-08-29 15:57:54 +0200
committerHenrik Nord <[email protected]>2011-09-21 17:03:43 +0200
commitcc087c398941302629ac6fd140639e65a9516cb8 (patch)
tree28ae7211396faf527cea79a14139a91b68f4446e /lib/tools/src/cover.erl
parent3d31498a0d08a9cf572fc966c025ed44ef15e831 (diff)
downloadotp-cc087c398941302629ac6fd140639e65a9516cb8.tar.gz
otp-cc087c398941302629ac6fd140639e65a9516cb8.tar.bz2
otp-cc087c398941302629ac6fd140639e65a9516cb8.zip
[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
Diffstat (limited to 'lib/tools/src/cover.erl')
-rw-r--r--lib/tools/src/cover.erl4
1 files changed, 2 insertions, 2 deletions
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.