From c82e9fad33302ff24fdddbd50f110c06d4eb81d4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Lo=C3=AFc=20Hoguin?= <essen@ninenines.eu>
Date: Fri, 5 Apr 2013 13:06:24 +0200
Subject: Use erlang:demonitor(Ref, [flush]) where applicable

---
 lib/compiler/test/receive_SUITE_data/ref_opt/yes_5.erl | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

(limited to 'lib/compiler')

diff --git a/lib/compiler/test/receive_SUITE_data/ref_opt/yes_5.erl b/lib/compiler/test/receive_SUITE_data/ref_opt/yes_5.erl
index 3f02fba6a6..5070e3e546 100644
--- a/lib/compiler/test/receive_SUITE_data/ref_opt/yes_5.erl
+++ b/lib/compiler/test/receive_SUITE_data/ref_opt/yes_5.erl
@@ -24,11 +24,7 @@ do_call(Process, Label, Request, Timeout) ->
 		{'DOWN', Mref, _, _, Reason} ->
 		    exit(Reason)
 	    after Timeout ->
-		    erlang:demonitor(Mref),
-		    receive
-			{'DOWN', Mref, _, _, _} -> true
-		    after 0 -> true
-		    end,
+		    erlang:demonitor(Mref, [flush]),
 		    exit(timeout)
 	    end
     catch
-- 
cgit v1.2.3