summaryrefslogtreecommitdiffstats
path: root/libmount/src
diff options
context:
space:
mode:
authorOndrej Oprala2014-03-13 11:53:31 +0100
committerOndrej Oprala2014-03-13 11:53:31 +0100
commit274228fecc76877224501177b46c19d9715a6ada (patch)
treeeb7230d86ec700a2fac47dcf343fe968f6ac8f09 /libmount/src
parentlibfdisk: use include/debug.h (diff)
downloadkernel-qcow2-util-linux-274228fecc76877224501177b46c19d9715a6ada.tar.gz
kernel-qcow2-util-linux-274228fecc76877224501177b46c19d9715a6ada.tar.xz
kernel-qcow2-util-linux-274228fecc76877224501177b46c19d9715a6ada.zip
clean up redundant macros and defines
Signed-off-by: Ondrej Oprala <ooprala@redhat.com>
Diffstat (limited to 'libmount/src')
-rw-r--r--libmount/src/init.c2
-rw-r--r--libmount/src/mountP.h10
-rw-r--r--libmount/src/test.c2
3 files changed, 2 insertions, 12 deletions
diff --git a/libmount/src/init.c b/libmount/src/init.c
index 19278bb89..d3aef7fa0 100644
--- a/libmount/src/init.c
+++ b/libmount/src/init.c
@@ -29,7 +29,7 @@ UL_DEBUG_DEFINE_MASK(libmount);
*/
void mnt_init_debug(int mask)
{
- INIT_DBG(mask);
+ __UL_INIT_DEBUG(libmount, MNT_DEBUG_, mask, LIBMOUNT_DEBUG);
if (libmount_debug_mask != MNT_DEBUG_INIT) {
const char *ver = NULL;
diff --git a/libmount/src/mountP.h b/libmount/src/mountP.h
index 1081c0d2f..e703f9bb7 100644
--- a/libmount/src/mountP.h
+++ b/libmount/src/mountP.h
@@ -55,12 +55,10 @@
#define MNT_DEF_FLAG(m) UL_DEFINE_FLAG(MNT_DEBUG_, m)
-#ifdef CONFIG_LIBMOUNT_DEBUG
# include <stdio.h>
# include <stdarg.h>
#define DBG(m, x) do { __UL_DBG(libmount, MNT_DEBUG_, m, x); } while (0)
-#define INIT_DBG(m) do { __UL_INIT_DEBUG(libmount, MNT_DEBUG_, m, LIBMOUNT_DEBUG); } while (0)
# define WARN_REFCOUNT(m, o, r) \
do { \
@@ -106,14 +104,6 @@ mnt_debug_h(void *handler, const char *mesg, ...)
fputc('\n', stderr);
}
-#else /* !CONFIG_LIBMOUNT_DEBUG */
-# define WARN_REFCOUNT(m,o,r) do { ; } while (0)
-# define ON_DBG(m,x) do { ; } while (0)
-# define DBG(m,x) do { ; } while (0)
-# define INIT_DBG(m,x) do { ; } while (0)
-# define DBG_FLUSH do { ; } while(0)
-#endif
-
/* extension for files in the directory */
#define MNT_MNTTABDIR_EXT ".fstab"
diff --git a/libmount/src/test.c b/libmount/src/test.c
index 40c344fc2..2da00b40d 100644
--- a/libmount/src/test.c
+++ b/libmount/src/test.c
@@ -31,7 +31,7 @@ int mnt_run_test(struct libmnt_test *tests, int argc, char *argv[])
strcmp(argv[1], "-h") == 0)
goto usage;
- INIT_DBG(0);
+ mnt_init_debug(0);
for (ts = tests; ts->name; ts++) {
if (strcmp(ts->name, argv[1]) == 0) {