ReactOS  0.4.12-dev-14-gd0c8636
daemon_debug.h
Go to the documentation of this file.
1 /* NFSv4.1 client for Windows
2  * Copyright 2012 The Regents of the University of Michigan
3  *
4  * Olga Kornievskaia <aglo@umich.edu>
5  * Casey Bodley <cbodley@umich.edu>
6  *
7  * This library is free software; you can redistribute it and/or modify it
8  * under the terms of the GNU Lesser General Public License as published by
9  * the Free Software Foundation; either version 2.1 of the License, or (at
10  * your option) any later version.
11  *
12  * This library is distributed in the hope that it will be useful, but
13  * without any warranty; without even the implied warranty of merchantability
14  * or fitness for a particular purpose. See the GNU Lesser General Public
15  * License for more details.
16  *
17  * You should have received a copy of the GNU Lesser General Public License
18  * along with this library; if not, write to the Free Software Foundation,
19  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA
20  */
21 
22 #ifndef _DAEMON_DEBUG_
23 #define _DAEMON_DEBUG_
24 
25 #ifdef _DEBUG
26 /* use visual studio's debug heap */
27 # define _CRTDBG_MAP_ALLOC
28 # include <stdlib.h>
29 # include <crtdbg.h>
30 #else
31 # include <stdlib.h>
32 #endif
33 
34 #define DEFAULT_DEBUG_LEVEL 1
35 
36 
37 /* daemon_debug.h */
38 void set_debug_level(int level);
39 void dprintf(int level, LPCSTR format, ...);
40 void eprintf(LPCSTR format, ...);
41 
43 void print_nfs_access_mask(int on, int m);
44 void print_hexbuf_no_asci(int on, unsigned char *title, unsigned char *buf, int len);
45 void print_hexbuf(int level, unsigned char *title, unsigned char *buf, int len);
46 void print_create_attributes(int level, DWORD create_opts);
47 void print_disposition(int level, DWORD disposition);
48 void print_access_mask(int level, DWORD access_mask);
49 void print_share_mode(int level, DWORD mode);
50 void print_file_id_both_dir_info(int level, FILE_ID_BOTH_DIR_INFO *p);
51 void print_opcode(int level, DWORD opcode);
52 const char* opcode2string(DWORD opcode);
53 const char* nfs_opnum_to_string(int opnum);
54 const char* nfs_error_string(int status);
55 const char* rpc_error_string(int status);
56 const char* gssauth_string(int type);
57 void print_condwait_status(int level, int status);
58 void print_sr_status_flags(int level, int flags);
59 void open_log_files();
60 void close_log_files();
61 const char* secflavorop2name(DWORD sec_flavor);
62 
63 /* pnfs_debug.c */
64 enum pnfs_status;
65 enum pnfs_layout_type;
66 enum pnfs_iomode;
67 struct __pnfs_file_layout;
68 struct __pnfs_file_device;
69 
70 const char* pnfs_error_string(enum pnfs_status status);
72 const char* pnfs_iomode_string(enum pnfs_iomode iomode);
73 
74 void dprint_deviceid(int level, const char *title, const unsigned char *deviceid);
75 void dprint_layout(int level, const struct __pnfs_file_layout *layout);
76 void dprint_device(int level, const struct __pnfs_file_device *device);
77 
78 #endif
pnfs_status
Definition: pnfs.h:58
void open_log_files()
Definition: daemon_debug.c:40
GLint level
Definition: gl.h:1546
void print_hexbuf_no_asci(int on, unsigned char *title, unsigned char *buf, int len)
Definition: daemon_debug.c:112
const char * pnfs_iomode_string(enum pnfs_iomode iomode)
Definition: pnfs_debug.c:58
const char * nfs_error_string(int status)
Definition: daemon_debug.c:370
GLenum GLuint GLenum GLsizei const GLchar * buf
Definition: glext.h:7751
void close_log_files()
Definition: daemon_debug.c:59
GLenum GLclampf GLint GLenum GLuint GLenum GLenum GLsizei GLenum const GLvoid GLfloat GLfloat GLfloat GLfloat GLclampd GLint GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean GLboolean GLboolean GLboolean GLint GLenum GLsizei const GLvoid GLenum GLint GLenum GLint GLint GLsizei GLint GLenum GLint GLint GLint GLint GLsizei GLenum GLsizei const GLuint GLboolean GLenum GLenum GLint GLsizei GLenum GLsizei GLenum const GLvoid GLboolean const GLboolean GLenum const GLdouble const GLfloat const GLdouble const GLfloat GLenum GLint GLint GLint GLint GLint GLint GLenum GLfloat GLenum GLint GLenum GLsizei GLenum GLboolean GLenum GLdouble GLenum GLfloat GLenum GLenum GLfloat GLenum GLenum GLdouble GLenum GLenum GLint GLenum GLenum GLint GLenum GLuint GLenum GLvoid const GLubyte GLenum GLenum GLenum GLint GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLvoid GLenum GLint GLenum GLint GLenum GLenum GLint GLuint GLdouble GLfloat GLint GLshort GLubyte GLenum GLuint GLenum const GLfloat GLenum const GLint GLenum GLenum const GLfloat GLenum GLenum const GLint GLfloat const GLfloat GLenum opcode
Definition: glfuncs.h:172
const char * secflavorop2name(DWORD sec_flavor)
Definition: daemon_debug.c:558
void set_debug_level(int level)
Definition: daemon_debug.c:35
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
void print_file_id_both_dir_info(int level, FILE_ID_BOTH_DIR_INFO *p)
Definition: daemon_debug.c:228
void dprint_layout(int level, const struct __pnfs_file_layout *layout)
GLint GLint GLsizei GLsizei GLsizei GLint GLenum format
Definition: gl.h:1546
const char * rpc_error_string(int status)
Definition: daemon_debug.c:482
Definition: devices.h:39
void print_create_attributes(int level, DWORD create_opts)
Definition: daemon_debug.c:126
void print_opcode(int level, DWORD opcode)
Definition: daemon_debug.c:275
const char * pnfs_layout_type_string(enum pnfs_layout_type type)
Definition: pnfs_debug.c:48
const char * pnfs_error_string(enum pnfs_status status)
Definition: pnfs_debug.c:28
const char * LPCSTR
Definition: xmlstorage.h:183
const char * nfs_opnum_to_string(int opnum)
Definition: daemon_debug.c:305
const char * opcode2string(DWORD opcode)
Definition: daemon_debug.c:280
void dprintf(int level, LPCSTR format,...)
Definition: daemon_debug.c:72
pnfs_layout_type
Definition: pnfs.h:74
const char * gssauth_string(int type)
Definition: daemon_debug.c:504
unsigned long DWORD
Definition: ntddk_ex.h:95
GLbitfield flags
Definition: glext.h:7161
static DWORD layout
Definition: bitmap.c:46
GLenum GLsizei len
Definition: glext.h:6722
void dprint_device(int level, const struct __pnfs_file_device *device)
void print_access_mask(int level, DWORD access_mask)
Definition: daemon_debug.c:181
const GLfloat * m
Definition: glext.h:10848
void print_nfs_access_mask(int on, int m)
Definition: daemon_debug.c:640
void print_sr_status_flags(int level, int flags)
Definition: daemon_debug.c:525
void print_windows_access_mask(int on, ACCESS_MASK m)
Definition: daemon_debug.c:570
void print_disposition(int level, DWORD disposition)
Definition: daemon_debug.c:164
sec_flavor
Definition: nfs41_ops.h:861
void eprintf(LPCSTR format,...)
Definition: daemon_debug.c:86
void dprint_deviceid(int level, const char *title, const unsigned char *deviceid)
void print_share_mode(int level, DWORD mode)
Definition: daemon_debug.c:215
void print_condwait_status(int level, int status)
Definition: daemon_debug.c:513
GLfloat GLfloat p
Definition: glext.h:8902
pnfs_iomode
Definition: pnfs.h:80
static char title[]
Definition: ps.c:92
ULONG ACCESS_MASK
Definition: nt_native.h:40
void print_hexbuf(int level, unsigned char *title, unsigned char *buf, int len)
Definition: daemon_debug.c:98
Definition: ps.c:97