diff options
author | Yves-Alexis Perez <corsac@corsac.net> | 2017-04-01 16:26:44 +0200 |
---|---|---|
committer | Yves-Alexis Perez <corsac@corsac.net> | 2017-04-01 16:26:44 +0200 |
commit | 05ddd767992d68bb38c7f16ece142e8c2e9ae016 (patch) | |
tree | 302c618be306d4ed3c7f9fc58a1f6aaad4dd252f /src/libcharon/bus | |
parent | 25663e04c3ab01ef8dc9f906608282319cfea2db (diff) | |
download | vyos-strongswan-05ddd767992d68bb38c7f16ece142e8c2e9ae016.tar.gz vyos-strongswan-05ddd767992d68bb38c7f16ece142e8c2e9ae016.zip |
New upstream version 5.5.2
Diffstat (limited to 'src/libcharon/bus')
-rw-r--r-- | src/libcharon/bus/bus.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/libcharon/bus/bus.c b/src/libcharon/bus/bus.c index 6b3cea880..f4bba872f 100644 --- a/src/libcharon/bus/bus.c +++ b/src/libcharon/bus/bus.c @@ -233,6 +233,7 @@ static inline void unregister_logger(private_bus_t *this, logger_t *logger) enumerator_t *enumerator; linked_list_t *loggers; log_entry_t *entry, *found = NULL; + debug_t group; loggers = this->loggers[DBG_MAX]; enumerator = loggers->create_enumerator(loggers); @@ -249,17 +250,16 @@ static inline void unregister_logger(private_bus_t *this, logger_t *logger) if (found) { - level_t level = LEVEL_SILENT, vlevel = LEVEL_SILENT; - debug_t group; - for (group = 0; group < DBG_MAX; group++) { if (found->levels[group] > LEVEL_SILENT) { + level_t level = LEVEL_SILENT, vlevel = LEVEL_SILENT; + loggers = this->loggers[group]; loggers->remove(loggers, found, NULL); - loggers->find_first(loggers, (linked_list_match_t)find_max_levels, NULL, - &group, &level, &vlevel); + loggers->find_first(loggers, (linked_list_match_t)find_max_levels, + NULL, &group, &level, &vlevel); set_level(&this->max_level[group], level); set_level(&this->max_vlevel[group], vlevel); } |