summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libglusterfs/src/logging.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/libglusterfs/src/logging.c b/libglusterfs/src/logging.c
index 147ee383751..7081b184de9 100644
--- a/libglusterfs/src/logging.c
+++ b/libglusterfs/src/logging.c
@@ -793,7 +793,7 @@ _gf_log_callingfn (const char *domain, const char *file, const char *function,
if (this->loglevel && (level > this->loglevel))
goto out;
}
- if (level > ctx->log.loglevel)
+ if (level > ctx->log.loglevel || level == GF_LOG_NONE)
goto out;
static char *level_strings[] = {"", /* NONE */
@@ -982,7 +982,7 @@ _gf_msg_plain (gf_loglevel_t level, const char *fmt, ...)
if (this->loglevel && (level > this->loglevel))
goto out;
}
- if (level > ctx->log.loglevel)
+ if (level > ctx->log.loglevel || level == GF_LOG_NONE)
goto out;
va_start (ap, fmt);
@@ -1018,7 +1018,7 @@ _gf_msg_vplain (gf_loglevel_t level, const char *fmt, va_list ap)
if (this->loglevel && (level > this->loglevel))
goto out;
}
- if (level > ctx->log.loglevel)
+ if (level > ctx->log.loglevel || level == GF_LOG_NONE)
goto out;
ret = vasprintf (&msg, fmt, ap);
@@ -1050,7 +1050,7 @@ _gf_msg_plain_nomem (gf_loglevel_t level, const char *msg)
if (this->loglevel && (level > this->loglevel))
goto out;
}
- if (level > ctx->log.loglevel)
+ if (level > ctx->log.loglevel || level == GF_LOG_NONE)
goto out;
ret = _gf_msg_plain_internal (level, msg);
@@ -1082,7 +1082,7 @@ _gf_msg_backtrace_nomem (gf_loglevel_t level, int stacksize)
if (this->loglevel && (level > this->loglevel))
goto out;
}
- if (level > ctx->log.loglevel)
+ if (level > ctx->log.loglevel || level == GF_LOG_NONE)
goto out;
bt_size = backtrace (array, ((stacksize <= 200)? stacksize : 200));
@@ -1169,7 +1169,7 @@ _gf_msg_nomem (const char *domain, const char *file,
if (this->loglevel && (level > this->loglevel))
goto out;
}
- if (level > ctx->log.loglevel)
+ if (level > ctx->log.loglevel || level == GF_LOG_NONE)
goto out;
if (!domain || !file || !function) {
@@ -2038,7 +2038,7 @@ _gf_msg (const char *domain, const char *file, const char *function,
if (this->loglevel && (level > this->loglevel))
goto out;
}
- if (level > ctx->log.loglevel)
+ if (level > ctx->log.loglevel || level == GF_LOG_NONE)
goto out;
if (trace) {
@@ -2119,7 +2119,7 @@ _gf_log (const char *domain, const char *file, const char *function, int line,
if (this->loglevel && (level > this->loglevel))
goto out;
}
- if (level > ctx->log.loglevel)
+ if (level > ctx->log.loglevel || level == GF_LOG_NONE)
goto out;
static char *level_strings[] = {"", /* NONE */