Add -L/--log-level command line option to repmgr

Overrides any setting in the config file. This will replace the
-v/--verbose option.
This commit is contained in:
Ian Barwick
2015-11-13 20:54:58 +09:00
committed by Ian Barwick
parent 1725e90308
commit acc0ffa81f
4 changed files with 32 additions and 6 deletions

4
log.c
View File

@@ -39,7 +39,6 @@
/* #define REPMGR_DEBUG */
static int detect_log_level(const char *level);
static int detect_log_facility(const char *facility);
int log_type = REPMGR_STDERR;
@@ -217,7 +216,7 @@ logger_min_verbose(int minimum)
log_level = minimum;
}
static int
int
detect_log_level(const char *level)
{
if (!strcmp(level, "DEBUG"))
@@ -247,7 +246,6 @@ detect_log_facility(const char *facility)
if (!strncmp(facility, "LOCAL", 5) && strlen(facility) == 6)
{
local = atoi(&facility[5]);
switch (local)