Added/fixed some documentation reported by winapi_check.
[wine.git] / debugger / dbgmain.c
blob4f2a1fc75d25f15bd3d25c372127908add072e18
1 /*
2 * File dbgmain.c - main wrapper for internal debugger test bed.
4 * Copyright (C) 1997, Eric Youngdale.
5 */
6 #include <signal.h>
7 #include <X11/Xlib.h>
8 #include "config.h"
9 #include "ldt.h"
10 #include "windows.h"
11 #include "toolhelp.h"
12 #include "module.h"
13 #include "debugger.h"
14 #include "win.h"
15 #include "peexe.h"
16 #include "pe_image.h"
18 ldt_copy_entry ldt_copy[LDT_SIZE];
19 unsigned char ldt_flags_copy[LDT_SIZE];
21 Display * display;
23 int
24 XUngrabServer( Display * d )
26 return(0);
29 int
30 XFlush(Display * d )
32 return(0);
35 HTASK16 GetCurrentTask(void)
37 exit(0);
40 HMODULE16 GetExePtr(HANDLE16 h)
42 exit(0);
45 int PROFILE_GetWineIniString( const char *section, const char *key_name,
46 const char *def, char *buffer, int len )
48 exit(0);
52 void CLASS_DumpClass( struct tagCLASS *class )
54 exit(0);
57 void MODULE_DumpModule( HMODULE16 hmodule )
59 exit(0);
62 void QUEUE_DumpQueue( HQUEUE16 hQueue )
64 exit(0);
67 void WIN_DumpWindow( HWND hwnd )
69 exit(0);
73 void CLASS_WalkClasses(void)
75 exit(0);
78 void MODULE_WalkModules(void)
80 exit(0);
83 void QUEUE_WalkQueues(void)
85 exit(0);
88 void WIN_WalkWindows( HWND hwnd, int indent )
90 exit(0);
93 NE_MODULE *NE_GetPtr( HMODULE16 hModule )
95 exit(0);
98 FARPROC16 NE_GetEntryPoint( HMODULE16 hModule, WORD ordinal )
100 exit(0);
103 void LDT_Print( int start, int length )
105 exit(0);
108 LPVOID GlobalLock16(HGLOBAL16 h)
110 exit(0);
113 BOOL16 ModuleFirst16(MODULEENTRY *lpModule)
115 return 0;
118 BOOL16 ModuleNext16(MODULEENTRY *lpModule)
120 return 0;
123 BOOL16 IsBadReadPtr16(SEGPTR s,UINT16 o)
125 exit(0);
128 BOOL IsBadReadPtr(LPCVOID s,UINT o)
130 exit(0);
133 struct qwert
135 unsigned flag1:1;
136 unsigned flag3:3;
137 signed remain:11;
138 unsigned whatsup:17;
139 } vvv;
141 int xyzzy(const char * qwe, int ijk)
143 return strlen(qwe) + ijk;
146 unsigned int * xxx;
147 unsigned int * yyy;
149 int xxx3[10];
151 char vdv[100];
153 struct deferred_debug_info
155 struct deferred_debug_info * next;
156 char * load_addr;
157 char * module_name;
158 char * dbg_info;
159 int dbg_size;
160 PIMAGE_DEBUG_DIRECTORY dbgdir;
161 struct pe_data * pe;
162 PIMAGE_SECTION_HEADER sectp;
163 int nsect;
164 short int dbg_index;
165 char loaded;
168 struct CodeViewDebug
170 char cv_nbtype[8];
171 unsigned int cv_timestamp;
172 char cv_unknown[4];
173 char cv_name[1];
176 test_pdbstuff(void)
178 struct deferred_debug_info deefer;
179 IMAGE_DEBUG_DIRECTORY dinfo;
180 struct CodeViewDebug cdebug;
181 IMAGE_SECTION_HEADER sects[10];
183 memset(&deefer, 0, sizeof(deefer));
184 memset(&dinfo, 0, sizeof(dinfo));
185 memset(&cdebug, 0, sizeof(cdebug));
186 memset(&sects, 0, sizeof(sects));
188 deefer.dbg_info = (char *) &cdebug;
189 dinfo.TimeStamp = 812932395;
190 cdebug.cv_timestamp = 833392137 /* 841951397 */;
191 deefer.dbgdir = &dinfo;
192 deefer.sectp = sects;
193 deefer.nsect = 10;
195 DEBUG_InitTypes();
196 DEBUG_ProcessPDBFile(&deefer, "../dumpexe.pdb");
200 main(int argc, char * argv[])
202 SIGCONTEXT reg;
204 strcpy(vdv, "This is a test");
205 memset(&vvv, 0xff, sizeof(vvv));
206 vvv.whatsup = 0;
207 vvv.flag3 = 0;
208 vvv.remain = 0x401;
209 argv0 = argv[0];
210 xxx = (unsigned int*) &vvv;
211 yyy = xxx + 5;
212 xxx3[5] = 7;
214 test_pdbstuff();
216 memset(&reg, 0, sizeof(reg));
217 wine_debug(SIGSEGV, &reg);
218 return 0;