aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnders Svensson <[email protected]>2011-09-23 17:01:39 +0200
committerAnders Svensson <[email protected]>2011-09-26 16:59:44 +0200
commit48a715dec34a61208e82f91b49a3d3670a62d7ce (patch)
tree126d813610e473d34287654d84a5eee0d382a581
parent97f3a064f27843a9f825210c1c7a27075b7b3ad7 (diff)
downloadotp-48a715dec34a61208e82f91b49a3d3670a62d7ce.tar.gz
otp-48a715dec34a61208e82f91b49a3d3670a62d7ce.tar.bz2
otp-48a715dec34a61208e82f91b49a3d3670a62d7ce.zip
Fix improper use of error_logger:info_report/2
Function doesn't take a format string and arguments as we called it. Instead use error_logger:info_report/1 and use the same report format as used for warning and error reports.
-rw-r--r--lib/diameter/src/app/diameter_lib.erl13
1 files changed, 4 insertions, 9 deletions
diff --git a/lib/diameter/src/app/diameter_lib.erl b/lib/diameter/src/app/diameter_lib.erl
index b5c0e1bf6a..36cc201dde 100644
--- a/lib/diameter/src/app/diameter_lib.erl
+++ b/lib/diameter/src/app/diameter_lib.erl
@@ -46,14 +46,9 @@
report(Reason, MFA) ->
info_report(Reason, MFA).
-info_report(Reason, {M,F,A}) ->
- error_logger:info_report(" Reason: ~p~n"
- " Pid: ~p~n"
- " Node: ~p~n"
- " Module: ~p~n"
- " Function: ~p~n"
- "Arguments: ~p~n",
- [Reason, self(), node(), M, F, A]).
+info_report(Reason, MFA) ->
+ report(fun error_logger:info_report/1, Reason, MFA),
+ true.
%%% ---------------------------------------------------------------------------
%%% # error_report(Reason, MFA)
@@ -69,7 +64,7 @@ warning_report(Reason, MFA) ->
report(fun error_logger:warning_report/1, Reason, MFA).
report(Fun, Reason, MFA) ->
- Fun([{reason, Reason}, {who, self()}, {where, node()}, {what, MFA}]),
+ Fun([{why, Reason}, {who, self()}, {what, MFA}]),
false.
%%% ---------------------------------------------------------------------------