map any attempt to log to an unknown logsink to the core logsink, fixes 577
git-svn-id: file:///home/svn/framework3/trunk@7653 4d416f70-5f16-0410-b530-b9f4589650da
This commit is contained in:
parent
ed7b7ac6f0
commit
125f0aab0a
|
@ -87,6 +87,9 @@ class LogDispatcher
|
|||
# Performs the actual log operation against the supplied source
|
||||
#
|
||||
def log(sev, src, level, msg, from)
|
||||
if (log_sinks[src].nil? and log_sinks['core'])
|
||||
register_log_source(src, log_sinks['core'], get_log_level('core'))
|
||||
end
|
||||
log_sinks_lock.synchronize {
|
||||
if ((sink = log_sinks[src]))
|
||||
next if (log_levels[src] and level > log_levels[src])
|
||||
|
@ -176,4 +179,4 @@ def get_log_level(src)
|
|||
end
|
||||
|
||||
# Creates the global log dispatcher
|
||||
$dispatcher = Rex::Logging::LogDispatcher.new
|
||||
$dispatcher = Rex::Logging::LogDispatcher.new
|
||||
|
|
Loading…
Reference in New Issue