If --dry-run specified, ensure minimum log level is INFO

When executed with --dry-run, repmgr outputs detail about what would
happen using log level INFO. If the log_level is configured to
NOTICE or higher, it's possible some or all of the --dry-run output
might not be displayed.

Addresses GitHub #441.
This commit is contained in:
Ian Barwick
2018-05-31 15:30:26 +09:00
parent 28ea2e48de
commit c54bb73fb2
3 changed files with 19 additions and 1 deletions

7
log.c
View File

@@ -329,6 +329,13 @@ logger_set_terse(void)
}
void
logger_set_min_level(int min_log_level)
{
if (min_log_level > log_level)
log_level = min_log_level;
}
int
detect_log_level(const char *level)
{