aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/test/nif_SUITE.erl
diff options
context:
space:
mode:
authorSverker Eriksson <[email protected]>2017-02-20 19:16:48 +0100
committerSverker Eriksson <[email protected]>2017-02-20 19:16:48 +0100
commit5adbf961a3c79a6782f8be8336ec26594754e9e8 (patch)
tree73e52c37a6d3fb160e29d7a94922b9a15f62a295 /erts/emulator/test/nif_SUITE.erl
parente93c9afd2415e3d500fe631d047c75fe47487baf (diff)
downloadotp-5adbf961a3c79a6782f8be8336ec26594754e9e8.tar.gz
otp-5adbf961a3c79a6782f8be8336ec26594754e9e8.tar.bz2
otp-5adbf961a3c79a6782f8be8336ec26594754e9e8.zip
erts: Add enif_compare_monitors
# Conflicts: # erts/emulator/test/nif_SUITE_data/nif_SUITE.c
Diffstat (limited to 'erts/emulator/test/nif_SUITE.erl')
-rw-r--r--erts/emulator/test/nif_SUITE.erl11
1 files changed, 7 insertions, 4 deletions
diff --git a/erts/emulator/test/nif_SUITE.erl b/erts/emulator/test/nif_SUITE.erl
index d88ac01e46..9932b526b9 100644
--- a/erts/emulator/test/nif_SUITE.erl
+++ b/erts/emulator/test/nif_SUITE.erl
@@ -598,10 +598,11 @@ monitor_process_a(Config) ->
end
end),
R_ptr = alloc_monitor_resource_nif(),
- {0, Mon} = monitor_process_nif(R_ptr, Pid, UseMsgEnv, self()),
+ {0, Mon1} = monitor_process_nif(R_ptr, Pid, UseMsgEnv, self()),
[R_ptr] = monitored_by(Pid),
Terminator(Pid),
- [{monitor_resource_down, R_ptr, Pid, Mon}] = flush(),
+ [{monitor_resource_down, R_ptr, Pid, Mon2}] = flush(),
+ 0 = compare_monitors_nif(Mon1, Mon2),
[] = last_resource_dtor_call(),
ok = release_resource(R_ptr),
{R_ptr, _, 1} = last_resource_dtor_call()
@@ -650,8 +651,9 @@ monitor_process_c(Config) ->
Papa ! {self(), done, R_ptr, Mon},
exit
end),
- [{Pid, done, R_ptr, Mon},
- {monitor_resource_down, R_ptr, Pid, Mon}] = flush(),
+ [{Pid, done, R_ptr, Mon1},
+ {monitor_resource_down, R_ptr, Pid, Mon2}] = flush(),
+ compare_monitors_nif(Mon1, Mon2),
{R_ptr, _, 1} = last_resource_dtor_call(),
ok.
@@ -2657,6 +2659,7 @@ last_fd_stop_call() -> ?nif_stub.
alloc_monitor_resource_nif() -> ?nif_stub.
monitor_process_nif(_,_,_,_) -> ?nif_stub.
demonitor_process_nif(_,_) -> ?nif_stub.
+compare_monitors_nif(_,_) -> ?nif_stub.
monitor_frenzy_nif(_,_,_,_) -> ?nif_stub.
%% maps