aboutsummaryrefslogtreecommitdiffstats
path: root/lib/snmp/src/manager/snmpm.erl
diff options
context:
space:
mode:
authorMicael Karlberg <[email protected]>2013-11-19 12:41:02 +0100
committerMicael Karlberg <[email protected]>2013-11-19 12:41:02 +0100
commit1508a71c3ec41347e6e34c57671028f2e4640680 (patch)
treef00bffa5c3765b6886b47ef30b4f31eb37122762 /lib/snmp/src/manager/snmpm.erl
parent08b6fcf4c00deb2efb7ddb759b430ab7effa3cc8 (diff)
downloadotp-1508a71c3ec41347e6e34c57671028f2e4640680.tar.gz
otp-1508a71c3ec41347e6e34c57671028f2e4640680.tar.bz2
otp-1508a71c3ec41347e6e34c57671028f2e4640680.zip
[snmp] Cleanup and changed atl conversion block default
Changed the default value for the Audit Trail Log conversion to true. Also some cleanup. OTP-11396
Diffstat (limited to 'lib/snmp/src/manager/snmpm.erl')
-rw-r--r--lib/snmp/src/manager/snmpm.erl21
1 files changed, 11 insertions, 10 deletions
diff --git a/lib/snmp/src/manager/snmpm.erl b/lib/snmp/src/manager/snmpm.erl
index a749153ece..379abe933e 100644
--- a/lib/snmp/src/manager/snmpm.erl
+++ b/lib/snmp/src/manager/snmpm.erl
@@ -118,6 +118,7 @@
-include("snmp_verbosity.hrl").
-define(DEFAULT_AGENT_PORT, 161).
+-define(ATL_BLOCK_DEFAULT, true).
%% This function is called when the snmp application
@@ -782,7 +783,7 @@ log_to_txt(LogDir, Block)
LogFile = ?audit_trail_log_file,
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block);
log_to_txt(LogDir, Mibs) ->
- Block = false,
+ Block = ?ATL_BLOCK_DEFAULT,
OutFile = "snmpm_log.txt",
LogName = ?audit_trail_log_name,
LogFile = ?audit_trail_log_file,
@@ -804,7 +805,7 @@ log_to_txt(LogDir, Mibs, Block)
LogFile = ?audit_trail_log_file,
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block);
log_to_txt(LogDir, Mibs, OutFile) ->
- Block = false,
+ Block = ?ATL_BLOCK_DEFAULT,
LogName = ?audit_trail_log_name,
LogFile = ?audit_trail_log_file,
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block).
@@ -826,7 +827,7 @@ log_to_txt(LogDir, Mibs, OutFile, Block)
LogFile = ?audit_trail_log_file,
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block);
log_to_txt(LogDir, Mibs, OutFile, LogName) ->
- Block = false,
+ Block = ?ATL_BLOCK_DEFAULT,
LogFile = ?audit_trail_log_file,
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block).
@@ -848,7 +849,7 @@ log_to_txt(LogDir, Mibs, OutFile, LogName, Block)
LogFile = ?audit_trail_log_file,
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block);
log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile) ->
- Block = false,
+ Block = ?ATL_BLOCK_DEFAULT,
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block).
-spec log_to_txt(LogDir :: snmp:dir(),
@@ -870,7 +871,7 @@ log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block)
when ((Block =:= true) orelse (Block =:= false)) ->
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block);
log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Start) ->
- Block = false,
+ Block = ?ATL_BLOCK_DEFAULT,
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block, Start).
-spec log_to_txt(LogDir :: snmp:dir(),
@@ -894,7 +895,7 @@ log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block, Start)
when ((Block =:= true) orelse (Block =:= false)) ->
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block, Start);
log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Start, Stop) ->
- Block = false,
+ Block = ?ATL_BLOCK_DEFAULT,
snmp:log_to_txt(LogDir, Mibs, OutFile, LogName, LogFile, Block, Start, Stop).
-spec log_to_txt(LogDir :: snmp:dir(),
@@ -931,7 +932,7 @@ log_to_io(LogDir, Mibs, Block)
LogFile = ?audit_trail_log_file,
snmp:log_to_io(LogDir, Mibs, LogName, LogFile, Block);
log_to_io(LogDir, Mibs, LogName) ->
- Block = false,
+ Block = ?ATL_BLOCK_DEFAULT,
LogFile = ?audit_trail_log_file,
snmp:log_to_io(LogDir, Mibs, LogName, LogFile, Block).
@@ -940,21 +941,21 @@ log_to_io(LogDir, Mibs, LogName, Block)
LogFile = ?audit_trail_log_file,
snmp:log_to_io(LogDir, Mibs, LogName, LogFile, Block);
log_to_io(LogDir, Mibs, LogName, LogFile) ->
- Block = false,
+ Block = ?ATL_BLOCK_DEFAULT,
snmp:log_to_io(LogDir, Mibs, LogName, LogFile, Block).
log_to_io(LogDir, Mibs, LogName, LogFile, Block)
when ((Block =:= true) orelse (Block =:= false)) ->
snmp:log_to_io(LogDir, Mibs, LogName, LogFile, Block);
log_to_io(LogDir, Mibs, LogName, LogFile, Start) ->
- Block = false,
+ Block = ?ATL_BLOCK_DEFAULT,
snmp:log_to_io(LogDir, Mibs, LogName, LogFile, Block, Start).
log_to_io(LogDir, Mibs, LogName, LogFile, Block, Start)
when ((Block =:= true) orelse (Block =:= false)) ->
snmp:log_to_io(LogDir, Mibs, LogName, LogFile, Block, Start);
log_to_io(LogDir, Mibs, LogName, LogFile, Start, Stop) ->
- Block = false,
+ Block = ?ATL_BLOCK_DEFAULT,
snmp:log_to_io(LogDir, Mibs, LogName, LogFile, Block, Start, Stop).
log_to_io(LogDir, Mibs, LogName, LogFile, Block, Start, Stop) ->