aboutsummaryrefslogtreecommitdiffstats
path: root/lib/mnesia/src/mnesia_subscr.erl
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2013-06-10 10:47:10 +0200
committerDan Gudmundsson <[email protected]>2013-06-10 10:47:10 +0200
commita49832f74d364e01d9fb7a98caf3ca942a0a0341 (patch)
treeaf65b1bbdb4bd0a8656a9705c67274433680cfb6 /lib/mnesia/src/mnesia_subscr.erl
parent9e20ac47b7107dcda818b20f6622e56f52a5ef64 (diff)
parentcb5bd884c96bdb0590162638530ea52b8f549985 (diff)
downloadotp-a49832f74d364e01d9fb7a98caf3ca942a0a0341.tar.gz
otp-a49832f74d364e01d9fb7a98caf3ca942a0a0341.tar.bz2
otp-a49832f74d364e01d9fb7a98caf3ca942a0a0341.zip
Merge branch 'dgud/mnesia-unsubscribe-fix' into maint
* dgud/mnesia-unsubscribe-fix: mnesia: Fix (timing issue) testcase mnesia: Fix unsubscribe error handling
Diffstat (limited to 'lib/mnesia/src/mnesia_subscr.erl')
-rw-r--r--lib/mnesia/src/mnesia_subscr.erl10
1 files changed, 7 insertions, 3 deletions
diff --git a/lib/mnesia/src/mnesia_subscr.erl b/lib/mnesia/src/mnesia_subscr.erl
index 415c69d508..8f78dc55e8 100644
--- a/lib/mnesia/src/mnesia_subscr.erl
+++ b/lib/mnesia/src/mnesia_subscr.erl
@@ -1,7 +1,7 @@
%%
%% %CopyrightBegin%
%%
-%% Copyright Ericsson AB 1997-2010. All Rights Reserved.
+%% Copyright Ericsson AB 1997-2013. All Rights Reserved.
%%
%% The contents of this file are subject to the Erlang Public License,
%% Version 1.1, (the "License"); you may not use this file except in
@@ -447,8 +447,12 @@ deactivate(ClientPid, What, Var, SubscrTab) ->
{'EXIT', _} ->
unlink(ClientPid)
end,
- del_subscr(Var, What, ClientPid),
- {ok, node()}.
+ try
+ del_subscr(Var, What, ClientPid),
+ {ok, node()}
+ catch _:_ ->
+ {error, badarg}
+ end.
del_subscr(subscribers, _What, Pid) ->
mnesia_lib:del(subscribers, Pid);