aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2019-02-22 09:57:17 +0100
committerDan Gudmundsson <[email protected]>2019-02-22 09:57:17 +0100
commit5e40f34b27454b38c1eff389e9c68c84a1d26290 (patch)
tree9b004d1c494c844e4557bccd035e13298806f768 /lib
parentcb9b1267f2465a129a1f5de5cf812bcfd5a7a9f4 (diff)
downloadotp-5e40f34b27454b38c1eff389e9c68c84a1d26290.tar.gz
otp-5e40f34b27454b38c1eff389e9c68c84a1d26290.tar.bz2
otp-5e40f34b27454b38c1eff389e9c68c84a1d26290.zip
mnesia: Avoid raise in overload reports
Several processes could invoke adjust_log_writes, which could cause overload reports.
Diffstat (limited to 'lib')
-rw-r--r--lib/mnesia/src/mnesia_dumper.erl6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/mnesia/src/mnesia_dumper.erl b/lib/mnesia/src/mnesia_dumper.erl
index a2880d6cf4..cb2ee504f9 100644
--- a/lib/mnesia/src/mnesia_dumper.erl
+++ b/lib/mnesia/src/mnesia_dumper.erl
@@ -67,10 +67,10 @@ get_log_writes() ->
incr_log_writes() ->
Left = mnesia_lib:incr_counter(trans_log_writes_left, -1),
if
- Left > 0 ->
- ignore;
+ Left =:= 0 ->
+ adjust_log_writes(true);
true ->
- adjust_log_writes(true)
+ ignore
end.
adjust_log_writes(DoCast) ->