summaryrefslogtreecommitdiffstats
path: root/src/util
diff options
context:
space:
mode:
authorMichal Zidek <mzidek@redhat.com>2012-11-19 13:10:39 +0100
committerJakub Hrozek <jhrozek@redhat.com>2012-11-26 20:59:52 +0100
commit2cb77cf2c239f33cccdadb79a3d7d4752d3a562f (patch)
treecc3b7a63fdf8711a882c3ee5eff6d80c8ca8094c /src/util
parent81b05adc4d904f5a92b95938ae21f1bb6bc94b9f (diff)
downloadsssd-2cb77cf2c239f33cccdadb79a3d7d4752d3a562f.tar.gz
sssd-2cb77cf2c239f33cccdadb79a3d7d4752d3a562f.tar.xz
sssd-2cb77cf2c239f33cccdadb79a3d7d4752d3a562f.zip
debug: print fatal and critical errors if debug level is unresolved
If global variable debug_level has value SSSDBG_UNRESOLVED, we should print at least fatal and critical errors. https://fedorahosted.org/sssd/ticket/1345
Diffstat (limited to 'src/util')
-rw-r--r--src/util/util.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/util/util.h b/src/util/util.h
index 9e55e5065..1f7c6c344 100644
--- a/src/util/util.h
+++ b/src/util/util.h
@@ -193,7 +193,10 @@ errno_t set_debug_file_from_fd(const int fd);
\param level the debug level, please use one of the SSSDBG*_ macros
*/
-#define DEBUG_IS_SET(level) (debug_level & (level))
+#define DEBUG_IS_SET(level) (debug_level & (level) || \
+ (debug_level == SSSDBG_UNRESOLVED && \
+ (level & (SSSDBG_FATAL_FAILURE | \
+ SSSDBG_CRIT_FAILURE))))
#define CONVERT_AND_SET_DEBUG_LEVEL(new_value) debug_level = ( \
((new_value) != SSSDBG_INVALID) \