Fixed a bug with the processing of HitTest.
[wine/multimedia.git] / debugger / dbgmain.c
blob1592e29b43287705582351236a2e81f7b1c16793
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 "pe_image.h"
17 ldt_copy_entry ldt_copy[LDT_SIZE];
18 unsigned char ldt_flags_copy[LDT_SIZE];
20 Display * display;
22 int
23 XUngrabServer( Display * d )
25 return(0);
28 int
29 XFlush(Display * d )
31 return(0);
34 HTASK16 GetCurrentTask(void)
36 exit(0);
39 HMODULE16 GetExePtr(HANDLE16 h)
41 exit(0);
44 int PROFILE_GetWineIniString( const char *section, const char *key_name,
45 const char *def, char *buffer, int len )
47 exit(0);
51 void CLASS_DumpClass( struct tagCLASS *class )
53 exit(0);
56 void MODULE_DumpModule( HMODULE16 hmodule )
58 exit(0);
61 void QUEUE_DumpQueue( HQUEUE16 hQueue )
63 exit(0);
66 void WIN_DumpWindow( HWND hwnd )
68 exit(0);
72 void CLASS_WalkClasses(void)
74 exit(0);
77 void MODULE_WalkModules(void)
79 exit(0);
82 void QUEUE_WalkQueues(void)
84 exit(0);
87 void WIN_WalkWindows( HWND hwnd, int indent )
89 exit(0);
92 NE_MODULE *NE_GetPtr( HMODULE16 hModule )
94 exit(0);
97 FARPROC16 NE_GetEntryPoint( HMODULE16 hModule, WORD ordinal )
99 exit(0);
102 void LDT_Print( int start, int length )
104 exit(0);
107 LPVOID GlobalLock16(HGLOBAL16 h)
109 exit(0);
112 BOOL16 ModuleFirst16(MODULEENTRY *lpModule)
114 return 0;
117 BOOL16 ModuleNext16(MODULEENTRY *lpModule)
119 return 0;
122 BOOL16 IsBadReadPtr16(SEGPTR s,UINT16 o)
124 exit(0);
127 BOOL IsBadReadPtr(LPCVOID s,UINT o)
129 exit(0);
132 struct qwert
134 unsigned flag1:1;
135 unsigned flag3:3;
136 signed remain:11;
137 unsigned whatsup:17;
138 } vvv;
140 int xyzzy(const char * qwe, int ijk)
142 return strlen(qwe) + ijk;
145 unsigned int * xxx;
146 unsigned int * yyy;
148 int xxx3[10];
150 char vdv[100];
152 struct deferred_debug_info
154 struct deferred_debug_info * next;
155 char * load_addr;
156 char * module_name;
157 char * dbg_info;
158 int dbg_size;
159 PIMAGE_DEBUG_DIRECTORY dbgdir;
160 struct pe_data * pe;
161 PIMAGE_SECTION_HEADER sectp;
162 int nsect;
163 short int dbg_index;
164 char loaded;
167 struct CodeViewDebug
169 char cv_nbtype[8];
170 unsigned int cv_timestamp;
171 char cv_unknown[4];
172 char cv_name[1];
175 test_pdbstuff(void)
177 struct deferred_debug_info deefer;
178 IMAGE_DEBUG_DIRECTORY dinfo;
179 struct CodeViewDebug cdebug;
180 IMAGE_SECTION_HEADER sects[10];
182 memset(&deefer, 0, sizeof(deefer));
183 memset(&dinfo, 0, sizeof(dinfo));
184 memset(&cdebug, 0, sizeof(cdebug));
185 memset(&sects, 0, sizeof(sects));
187 deefer.dbg_info = (char *) &cdebug;
188 dinfo.TimeStamp = 812932395;
189 cdebug.cv_timestamp = 833392137 /* 841951397 */;
190 deefer.dbgdir = &dinfo;
191 deefer.sectp = sects;
192 deefer.nsect = 10;
194 DEBUG_InitTypes();
195 DEBUG_ProcessPDBFile(&deefer, "../dumpexe.pdb");
199 main(int argc, char * argv[])
201 SIGCONTEXT reg;
203 strcpy(vdv, "This is a test");
204 memset(&vvv, 0xff, sizeof(vvv));
205 vvv.whatsup = 0;
206 vvv.flag3 = 0;
207 vvv.remain = 0x401;
208 argv0 = argv[0];
209 xxx = (unsigned int*) &vvv;
210 yyy = xxx + 5;
211 xxx3[5] = 7;
213 test_pdbstuff();
215 memset(&reg, 0, sizeof(reg));
216 wine_debug(SIGSEGV, &reg);
217 return 0;