summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuenter Kukkukk <kukks@samba.org>2013-02-27 05:34:05 +0100
committerJeremy Allison <jra@samba.org>2013-03-07 11:33:25 -0800
commitbb680efb0a40ecfe86206acef379e5f9e09ea5bf (patch)
tree8510b5f31d211e41fd50b43afdfcdbd263d14ba1
parent33a72968e566f47a3dcb5e8d752d47847d464337 (diff)
downloadsamba-bb680efb0a40ecfe86206acef379e5f9e09ea5bf.tar.gz
samba-bb680efb0a40ecfe86206acef379e5f9e09ea5bf.tar.bz2
samba-bb680efb0a40ecfe86206acef379e5f9e09ea5bf.zip
vfs_catia: add debug class for that module
Signed-off-by: Guenter Kukkukk <kukks@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
-rw-r--r--source3/modules/vfs_catia.c24
1 files changed, 23 insertions, 1 deletions
diff --git a/source3/modules/vfs_catia.c b/source3/modules/vfs_catia.c
index b9f241e240..3140df97f9 100644
--- a/source3/modules/vfs_catia.c
+++ b/source3/modules/vfs_catia.c
@@ -29,6 +29,11 @@
#include "includes.h"
#include "smbd/smbd.h"
+static int vfs_catia_debug_level = DBGC_VFS;
+
+#undef DBGC_CLASS
+#define DBGC_CLASS vfs_catia_debug_level
+
#define GLOBAL_SNUM 0xFFFFFFF
#define MAP_SIZE 0xFF
#define MAP_NUM 0x101 /* max unicode charval / MAP_SIZE */
@@ -929,6 +934,23 @@ static struct vfs_fn_pointers vfs_catia_fns = {
NTSTATUS vfs_catia_init(void)
{
- return smb_register_vfs(SMB_VFS_INTERFACE_VERSION, "catia",
+ NTSTATUS ret;
+
+ ret = smb_register_vfs(SMB_VFS_INTERFACE_VERSION, "catia",
&vfs_catia_fns);
+ if (!NT_STATUS_IS_OK(ret))
+ return ret;
+
+ vfs_catia_debug_level = debug_add_class("catia");
+ if (vfs_catia_debug_level == -1) {
+ vfs_catia_debug_level = DBGC_VFS;
+ DEBUG(0, ("vfs_catia: Couldn't register custom debugging "
+ "class!\n"));
+ } else {
+ DEBUG(10, ("vfs_catia: Debug class number of "
+ "'catia': %d\n", vfs_catia_debug_level));
+ }
+
+ return ret;
+
}