1 /* 2 * Support for Microsoft Debugging Extension API 3 * 4 * Copyright (C) 2010 Volodymyr Shcherbyna 5 * 6 * This library is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU Lesser General Public 8 * License as published by the Free Software Foundation; either 9 * version 2.1 of the License, or (at your option) any later version. 10 * 11 * This library is distributed in the hope that it will be useful, 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 * Lesser General Public License for more details. 15 * 16 * You should have received a copy of the GNU Lesser General Public 17 * License along with this library; if not, write to the Free Software 18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA 19 */ 20 21 #include <stdarg.h> 22 23 #define COBJMACROS 24 25 #include "windef.h" 26 #include "winbase.h" 27 #ifdef __REACTOS__ 28 #include "wine/winternl.h" 29 #else 30 #include "winternl.h" 31 #endif 32 #include "psapi.h" 33 34 #include "initguid.h" 35 #include "dbgeng.h" 36 37 #include "wine/debug.h" 38 #include "wine/heap.h" 39 #include "wine/list.h" 40 41 WINE_DEFAULT_DEBUG_CHANNEL(dbgeng); 42 43 extern NTSTATUS WINAPI NtSuspendProcess(HANDLE handle); 44 extern NTSTATUS WINAPI NtResumeProcess(HANDLE handle); 45 46 struct module_info 47 { 48 DEBUG_MODULE_PARAMETERS params; 49 char image_name[MAX_PATH]; 50 }; 51 52 struct target_process 53 { 54 struct list entry; 55 unsigned int pid; 56 unsigned int attach_flags; 57 HANDLE handle; 58 struct 59 { 60 struct module_info *info; 61 unsigned int loaded; 62 unsigned int unloaded; 63 BOOL initialized; 64 } modules; 65 ULONG cpu_type; 66 }; 67 68 struct debug_client 69 { 70 IDebugClient7 IDebugClient_iface; 71 IDebugDataSpaces IDebugDataSpaces_iface; 72 IDebugSymbols3 IDebugSymbols3_iface; 73 IDebugControl2 IDebugControl2_iface; 74 IDebugAdvanced IDebugAdvanced_iface; 75 IDebugSystemObjects IDebugSystemObjects_iface; 76 LONG refcount; 77 ULONG engine_options; 78 struct list targets; 79 IDebugEventCallbacks *event_callbacks; 80 }; 81 82 static struct target_process *debug_client_get_target(struct debug_client *debug_client) 83 { 84 if (list_empty(&debug_client->targets)) 85 return NULL; 86 87 return LIST_ENTRY(list_head(&debug_client->targets), struct target_process, entry); 88 } 89 90 static HRESULT debug_target_return_string(const char *str, char *buffer, unsigned int buffer_size, 91 unsigned int *size) 92 { 93 unsigned int len = strlen(str), dst_len; 94 95 if (size) 96 *size = len + 1; 97 98 if (buffer && buffer_size) 99 { 100 dst_len = min(len, buffer_size - 1); 101 if (dst_len) 102 memcpy(buffer, str, dst_len); 103 buffer[dst_len] = 0; 104 } 105 106 return len < buffer_size ? S_OK : S_FALSE; 107 } 108 109 static WORD debug_target_get_module_machine(struct target_process *target, HMODULE module) 110 { 111 IMAGE_DOS_HEADER dos = { 0 }; 112 WORD machine = 0; 113 114 ReadProcessMemory(target->handle, module, &dos, sizeof(dos), NULL); 115 if (dos.e_magic == IMAGE_DOS_SIGNATURE) 116 { 117 ReadProcessMemory(target->handle, (const char *)module + dos.e_lfanew + 4 /* PE signature */, &machine, 118 sizeof(machine), NULL); 119 } 120 121 return machine; 122 } 123 124 static DWORD debug_target_get_module_timestamp(struct target_process *target, HMODULE module) 125 { 126 IMAGE_DOS_HEADER dos = { 0 }; 127 DWORD timestamp = 0; 128 129 ReadProcessMemory(target->handle, module, &dos, sizeof(dos), NULL); 130 if (dos.e_magic == IMAGE_DOS_SIGNATURE) 131 { 132 ReadProcessMemory(target->handle, (const char *)module + dos.e_lfanew + 4 /* PE signature */ + 133 FIELD_OFFSET(IMAGE_FILE_HEADER, TimeDateStamp), ×tamp, sizeof(timestamp), NULL); 134 } 135 136 return timestamp; 137 } 138 139 static HRESULT debug_target_init_modules_info(struct target_process *target) 140 { 141 unsigned int i, count; 142 HMODULE *modules; 143 MODULEINFO info; 144 DWORD needed; 145 146 if (target->modules.initialized) 147 return S_OK; 148 149 if (!target->handle) 150 return E_UNEXPECTED; 151 152 needed = 0; 153 EnumProcessModules(target->handle, NULL, 0, &needed); 154 if (!needed) 155 return E_FAIL; 156 157 count = needed / sizeof(HMODULE); 158 159 if (!(modules = heap_alloc(count * sizeof(*modules)))) 160 return E_OUTOFMEMORY; 161 162 if (!(target->modules.info = heap_alloc_zero(count * sizeof(*target->modules.info)))) 163 { 164 heap_free(modules); 165 return E_OUTOFMEMORY; 166 } 167 168 if (EnumProcessModules(target->handle, modules, count * sizeof(*modules), &needed)) 169 { 170 for (i = 0; i < count; ++i) 171 { 172 if (!GetModuleInformation(target->handle, modules[i], &info, sizeof(info))) 173 { 174 WARN("Failed to get module information, error %d.\n", GetLastError()); 175 continue; 176 } 177 178 target->modules.info[i].params.Base = (ULONG_PTR)info.lpBaseOfDll; 179 target->modules.info[i].params.Size = info.SizeOfImage; 180 target->modules.info[i].params.TimeDateStamp = debug_target_get_module_timestamp(target, modules[i]); 181 182 GetModuleFileNameExA(target->handle, modules[i], target->modules.info[i].image_name, 183 ARRAY_SIZE(target->modules.info[i].image_name)); 184 } 185 } 186 187 target->cpu_type = debug_target_get_module_machine(target, modules[0]); 188 189 heap_free(modules); 190 191 target->modules.loaded = count; 192 target->modules.unloaded = 0; /* FIXME */ 193 194 target->modules.initialized = TRUE; 195 196 return S_OK; 197 } 198 199 static const struct module_info *debug_target_get_module_info(struct target_process *target, unsigned int i) 200 { 201 if (FAILED(debug_target_init_modules_info(target))) 202 return NULL; 203 204 if (i >= target->modules.loaded) 205 return NULL; 206 207 return &target->modules.info[i]; 208 } 209 210 static const struct module_info *debug_target_get_module_info_by_base(struct target_process *target, ULONG64 base) 211 { 212 unsigned int i; 213 214 if (FAILED(debug_target_init_modules_info(target))) 215 return NULL; 216 217 for (i = 0; i < target->modules.loaded; ++i) 218 { 219 if (target->modules.info[i].params.Base == base) 220 return &target->modules.info[i]; 221 } 222 223 return NULL; 224 } 225 226 static void debug_client_detach_target(struct target_process *target) 227 { 228 NTSTATUS status; 229 230 if (!target->handle) 231 return; 232 233 if (target->attach_flags & DEBUG_ATTACH_NONINVASIVE) 234 { 235 BOOL resume = !(target->attach_flags & DEBUG_ATTACH_NONINVASIVE_NO_SUSPEND); 236 237 if (resume) 238 { 239 if ((status = NtResumeProcess(target->handle))) 240 WARN("Failed to resume process, status %#x.\n", status); 241 } 242 } 243 244 CloseHandle(target->handle); 245 target->handle = NULL; 246 } 247 248 static struct debug_client *impl_from_IDebugClient(IDebugClient7 *iface) 249 { 250 return CONTAINING_RECORD(iface, struct debug_client, IDebugClient_iface); 251 } 252 253 static struct debug_client *impl_from_IDebugDataSpaces(IDebugDataSpaces *iface) 254 { 255 return CONTAINING_RECORD(iface, struct debug_client, IDebugDataSpaces_iface); 256 } 257 258 static struct debug_client *impl_from_IDebugSymbols3(IDebugSymbols3 *iface) 259 { 260 return CONTAINING_RECORD(iface, struct debug_client, IDebugSymbols3_iface); 261 } 262 263 static struct debug_client *impl_from_IDebugControl2(IDebugControl2 *iface) 264 { 265 return CONTAINING_RECORD(iface, struct debug_client, IDebugControl2_iface); 266 } 267 268 static struct debug_client *impl_from_IDebugAdvanced(IDebugAdvanced *iface) 269 { 270 return CONTAINING_RECORD(iface, struct debug_client, IDebugAdvanced_iface); 271 } 272 273 static struct debug_client *impl_from_IDebugSystemObjects(IDebugSystemObjects *iface) 274 { 275 return CONTAINING_RECORD(iface, struct debug_client, IDebugSystemObjects_iface); 276 } 277 278 static HRESULT STDMETHODCALLTYPE debugclient_QueryInterface(IDebugClient7 *iface, REFIID riid, void **obj) 279 { 280 struct debug_client *debug_client = impl_from_IDebugClient(iface); 281 282 TRACE("%p, %s, %p.\n", iface, debugstr_guid(riid), obj); 283 284 if (IsEqualIID(riid, &IID_IDebugClient) || 285 IsEqualIID(riid, &IID_IDebugClient2) || 286 IsEqualIID(riid, &IID_IDebugClient3) || 287 IsEqualIID(riid, &IID_IDebugClient4) || 288 IsEqualIID(riid, &IID_IDebugClient5) || 289 IsEqualIID(riid, &IID_IDebugClient6) || 290 IsEqualIID(riid, &IID_IDebugClient7) || 291 IsEqualIID(riid, &IID_IUnknown)) 292 { 293 *obj = iface; 294 } 295 else if (IsEqualIID(riid, &IID_IDebugDataSpaces)) 296 { 297 *obj = &debug_client->IDebugDataSpaces_iface; 298 } 299 else if (IsEqualIID(riid, &IID_IDebugSymbols) 300 || IsEqualIID(riid, &IID_IDebugSymbols2) 301 || IsEqualIID(riid, &IID_IDebugSymbols3)) 302 { 303 *obj = &debug_client->IDebugSymbols3_iface; 304 } 305 else if (IsEqualIID(riid, &IID_IDebugControl2) 306 || IsEqualIID(riid, &IID_IDebugControl)) 307 { 308 *obj = &debug_client->IDebugControl2_iface; 309 } 310 else if (IsEqualIID(riid, &IID_IDebugAdvanced)) 311 { 312 *obj = &debug_client->IDebugAdvanced_iface; 313 } 314 else if (IsEqualIID(riid, &IID_IDebugSystemObjects)) 315 { 316 *obj = &debug_client->IDebugSystemObjects_iface; 317 } 318 else 319 { 320 WARN("Unsupported interface %s.\n", debugstr_guid(riid)); 321 *obj = NULL; 322 return E_NOINTERFACE; 323 } 324 325 IUnknown_AddRef((IUnknown *)*obj); 326 return S_OK; 327 } 328 329 static ULONG STDMETHODCALLTYPE debugclient_AddRef(IDebugClient7 *iface) 330 { 331 struct debug_client *debug_client = impl_from_IDebugClient(iface); 332 ULONG refcount = InterlockedIncrement(&debug_client->refcount); 333 334 TRACE("%p, %d.\n", iface, refcount); 335 336 return refcount; 337 } 338 339 static void debug_target_free(struct target_process *target) 340 { 341 heap_free(target->modules.info); 342 heap_free(target); 343 } 344 345 static ULONG STDMETHODCALLTYPE debugclient_Release(IDebugClient7 *iface) 346 { 347 struct debug_client *debug_client = impl_from_IDebugClient(iface); 348 ULONG refcount = InterlockedDecrement(&debug_client->refcount); 349 struct target_process *cur, *cur2; 350 351 TRACE("%p, %d.\n", debug_client, refcount); 352 353 if (!refcount) 354 { 355 LIST_FOR_EACH_ENTRY_SAFE(cur, cur2, &debug_client->targets, struct target_process, entry) 356 { 357 debug_client_detach_target(cur); 358 list_remove(&cur->entry); 359 debug_target_free(cur); 360 } 361 if (debug_client->event_callbacks) 362 debug_client->event_callbacks->lpVtbl->Release(debug_client->event_callbacks); 363 heap_free(debug_client); 364 } 365 366 return refcount; 367 } 368 369 static HRESULT STDMETHODCALLTYPE debugclient_AttachKernel(IDebugClient7 *iface, ULONG flags, const char *options) 370 { 371 FIXME("%p, %#x, %s stub.\n", iface, flags, debugstr_a(options)); 372 373 return E_NOTIMPL; 374 } 375 376 static HRESULT STDMETHODCALLTYPE debugclient_GetKernelConnectionOptions(IDebugClient7 *iface, char *buffer, 377 ULONG buffer_size, ULONG *options_size) 378 { 379 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, options_size); 380 381 return E_NOTIMPL; 382 } 383 384 static HRESULT STDMETHODCALLTYPE debugclient_SetKernelConnectionOptions(IDebugClient7 *iface, const char *options) 385 { 386 FIXME("%p, %s stub.\n", iface, debugstr_a(options)); 387 388 return E_NOTIMPL; 389 } 390 391 static HRESULT STDMETHODCALLTYPE debugclient_StartProcessServer(IDebugClient7 *iface, ULONG flags, const char *options, 392 void *reserved) 393 { 394 FIXME("%p, %#x, %s, %p stub.\n", iface, flags, debugstr_a(options), reserved); 395 396 return E_NOTIMPL; 397 } 398 399 static HRESULT STDMETHODCALLTYPE debugclient_ConnectProcessServer(IDebugClient7 *iface, const char *remote_options, 400 ULONG64 *server) 401 { 402 FIXME("%p, %s, %p stub.\n", iface, debugstr_a(remote_options), server); 403 404 return E_NOTIMPL; 405 } 406 407 static HRESULT STDMETHODCALLTYPE debugclient_DisconnectProcessServer(IDebugClient7 *iface, ULONG64 server) 408 { 409 FIXME("%p, %s stub.\n", iface, wine_dbgstr_longlong(server)); 410 411 return E_NOTIMPL; 412 } 413 414 static HRESULT STDMETHODCALLTYPE debugclient_GetRunningProcessSystemIds(IDebugClient7 *iface, ULONG64 server, 415 ULONG *ids, ULONG count, ULONG *actual_count) 416 { 417 FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(server), ids, count, actual_count); 418 419 return E_NOTIMPL; 420 } 421 422 static HRESULT STDMETHODCALLTYPE debugclient_GetRunningProcessSystemIdByExecutableName(IDebugClient7 *iface, 423 ULONG64 server, const char *exe_name, ULONG flags, ULONG *id) 424 { 425 FIXME("%p, %s, %s, %#x, %p stub.\n", iface, wine_dbgstr_longlong(server), debugstr_a(exe_name), flags, id); 426 427 return E_NOTIMPL; 428 } 429 430 static HRESULT STDMETHODCALLTYPE debugclient_GetRunningProcessDescription(IDebugClient7 *iface, ULONG64 server, 431 ULONG systemid, ULONG flags, char *exe_name, ULONG exe_name_size, ULONG *actual_exe_name_size, 432 char *description, ULONG description_size, ULONG *actual_description_size) 433 { 434 FIXME("%p, %s, %u, %#x, %p, %u, %p, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(server), systemid, flags, 435 exe_name, exe_name_size, actual_exe_name_size, description, description_size, actual_description_size); 436 437 return E_NOTIMPL; 438 } 439 440 static HRESULT STDMETHODCALLTYPE debugclient_AttachProcess(IDebugClient7 *iface, ULONG64 server, ULONG pid, ULONG flags) 441 { 442 struct debug_client *debug_client = impl_from_IDebugClient(iface); 443 struct target_process *process; 444 445 TRACE("%p, %s, %u, %#x.\n", iface, wine_dbgstr_longlong(server), pid, flags); 446 447 if (server) 448 { 449 FIXME("Remote debugging is not supported.\n"); 450 return E_NOTIMPL; 451 } 452 453 if (!(process = heap_alloc_zero(sizeof(*process)))) 454 return E_OUTOFMEMORY; 455 456 process->pid = pid; 457 process->attach_flags = flags; 458 459 list_add_head(&debug_client->targets, &process->entry); 460 461 return S_OK; 462 } 463 464 static HRESULT STDMETHODCALLTYPE debugclient_CreateProcess(IDebugClient7 *iface, ULONG64 server, char *cmdline, 465 ULONG flags) 466 { 467 FIXME("%p, %s, %s, %#x stub.\n", iface, wine_dbgstr_longlong(server), debugstr_a(cmdline), flags); 468 469 return E_NOTIMPL; 470 } 471 472 static HRESULT STDMETHODCALLTYPE debugclient_CreateProcessAndAttach(IDebugClient7 *iface, ULONG64 server, char *cmdline, 473 ULONG create_flags, ULONG pid, ULONG attach_flags) 474 { 475 FIXME("%p, %s, %s, %#x, %u, %#x stub.\n", iface, wine_dbgstr_longlong(server), debugstr_a(cmdline), create_flags, 476 pid, attach_flags); 477 478 return E_NOTIMPL; 479 } 480 481 static HRESULT STDMETHODCALLTYPE debugclient_GetProcessOptions(IDebugClient7 *iface, ULONG *options) 482 { 483 FIXME("%p, %p stub.\n", iface, options); 484 485 return E_NOTIMPL; 486 } 487 488 static HRESULT STDMETHODCALLTYPE debugclient_AddProcessOptions(IDebugClient7 *iface, ULONG options) 489 { 490 FIXME("%p, %#x stub.\n", iface, options); 491 492 return E_NOTIMPL; 493 } 494 495 static HRESULT STDMETHODCALLTYPE debugclient_RemoveProcessOptions(IDebugClient7 *iface, ULONG options) 496 { 497 FIXME("%p, %#x stub.\n", iface, options); 498 499 return E_NOTIMPL; 500 } 501 502 static HRESULT STDMETHODCALLTYPE debugclient_SetProcessOptions(IDebugClient7 *iface, ULONG options) 503 { 504 FIXME("%p, %#x stub.\n", iface, options); 505 506 return E_NOTIMPL; 507 } 508 509 static HRESULT STDMETHODCALLTYPE debugclient_OpenDumpFile(IDebugClient7 *iface, const char *filename) 510 { 511 FIXME("%p, %s stub.\n", iface, debugstr_a(filename)); 512 513 return E_NOTIMPL; 514 } 515 516 static HRESULT STDMETHODCALLTYPE debugclient_WriteDumpFile(IDebugClient7 *iface, const char *filename, ULONG qualifier) 517 { 518 FIXME("%p, %s, %u stub.\n", iface, debugstr_a(filename), qualifier); 519 520 return E_NOTIMPL; 521 } 522 523 static HRESULT STDMETHODCALLTYPE debugclient_ConnectSession(IDebugClient7 *iface, ULONG flags, ULONG history_limit) 524 { 525 FIXME("%p, %#x, %u stub.\n", iface, flags, history_limit); 526 527 return E_NOTIMPL; 528 } 529 530 static HRESULT STDMETHODCALLTYPE debugclient_StartServer(IDebugClient7 *iface, const char *options) 531 { 532 FIXME("%p, %s stub.\n", iface, debugstr_a(options)); 533 534 return E_NOTIMPL; 535 } 536 537 static HRESULT STDMETHODCALLTYPE debugclient_OutputServers(IDebugClient7 *iface, ULONG output_control, 538 const char *machine, ULONG flags) 539 { 540 FIXME("%p, %u, %s, %#x stub.\n", iface, output_control, debugstr_a(machine), flags); 541 542 return E_NOTIMPL; 543 } 544 545 static HRESULT STDMETHODCALLTYPE debugclient_TerminateProcesses(IDebugClient7 *iface) 546 { 547 FIXME("%p stub.\n", iface); 548 549 return E_NOTIMPL; 550 } 551 552 static HRESULT STDMETHODCALLTYPE debugclient_DetachProcesses(IDebugClient7 *iface) 553 { 554 struct debug_client *debug_client = impl_from_IDebugClient(iface); 555 struct target_process *target; 556 557 TRACE("%p.\n", iface); 558 559 LIST_FOR_EACH_ENTRY(target, &debug_client->targets, struct target_process, entry) 560 { 561 debug_client_detach_target(target); 562 } 563 564 return S_OK; 565 } 566 567 static HRESULT STDMETHODCALLTYPE debugclient_EndSession(IDebugClient7 *iface, ULONG flags) 568 { 569 FIXME("%p, %#x stub.\n", iface, flags); 570 571 return E_NOTIMPL; 572 } 573 574 static HRESULT STDMETHODCALLTYPE debugclient_GetExitCode(IDebugClient7 *iface, ULONG *code) 575 { 576 FIXME("%p, %p stub.\n", iface, code); 577 578 return E_NOTIMPL; 579 } 580 581 static HRESULT STDMETHODCALLTYPE debugclient_DispatchCallbacks(IDebugClient7 *iface, ULONG timeout) 582 { 583 FIXME("%p, %u stub.\n", iface, timeout); 584 585 return E_NOTIMPL; 586 } 587 588 static HRESULT STDMETHODCALLTYPE debugclient_ExitDispatch(IDebugClient7 *iface, IDebugClient *client) 589 { 590 FIXME("%p, %p stub.\n", iface, client); 591 592 return E_NOTIMPL; 593 } 594 595 static HRESULT STDMETHODCALLTYPE debugclient_CreateClient(IDebugClient7 *iface, IDebugClient **client) 596 { 597 FIXME("%p, %p stub.\n", iface, client); 598 599 return E_NOTIMPL; 600 } 601 602 static HRESULT STDMETHODCALLTYPE debugclient_GetInputCallbacks(IDebugClient7 *iface, IDebugInputCallbacks **callbacks) 603 { 604 FIXME("%p, %p stub.\n", iface, callbacks); 605 606 return E_NOTIMPL; 607 } 608 609 static HRESULT STDMETHODCALLTYPE debugclient_SetInputCallbacks(IDebugClient7 *iface, IDebugInputCallbacks *callbacks) 610 { 611 FIXME("%p, %p stub.\n", iface, callbacks); 612 613 return E_NOTIMPL; 614 } 615 616 static HRESULT STDMETHODCALLTYPE debugclient_GetOutputCallbacks(IDebugClient7 *iface, IDebugOutputCallbacks **callbacks) 617 { 618 FIXME("%p, %p stub.\n", iface, callbacks); 619 620 return E_NOTIMPL; 621 } 622 623 static HRESULT STDMETHODCALLTYPE debugclient_SetOutputCallbacks(IDebugClient7 *iface, IDebugOutputCallbacks *callbacks) 624 { 625 FIXME("%p, %p stub.\n", iface, callbacks); 626 627 return E_NOTIMPL; 628 } 629 630 static HRESULT STDMETHODCALLTYPE debugclient_GetOutputMask(IDebugClient7 *iface, ULONG *mask) 631 { 632 FIXME("%p, %p stub.\n", iface, mask); 633 634 return E_NOTIMPL; 635 } 636 637 static HRESULT STDMETHODCALLTYPE debugclient_SetOutputMask(IDebugClient7 *iface, ULONG mask) 638 { 639 FIXME("%p, %#x stub.\n", iface, mask); 640 641 return E_NOTIMPL; 642 } 643 644 static HRESULT STDMETHODCALLTYPE debugclient_GetOtherOutputMask(IDebugClient7 *iface, IDebugClient *client, ULONG *mask) 645 { 646 FIXME("%p, %p, %p stub.\n", iface, client, mask); 647 648 return E_NOTIMPL; 649 } 650 651 static HRESULT STDMETHODCALLTYPE debugclient_SetOtherOutputMask(IDebugClient7 *iface, IDebugClient *client, ULONG mask) 652 { 653 FIXME("%p, %p, %#x stub.\n", iface, client, mask); 654 655 return E_NOTIMPL; 656 } 657 658 static HRESULT STDMETHODCALLTYPE debugclient_GetOutputWidth(IDebugClient7 *iface, ULONG *columns) 659 { 660 FIXME("%p, %p stub.\n", iface, columns); 661 662 return E_NOTIMPL; 663 } 664 665 static HRESULT STDMETHODCALLTYPE debugclient_SetOutputWidth(IDebugClient7 *iface, ULONG columns) 666 { 667 FIXME("%p, %u stub.\n", iface, columns); 668 669 return E_NOTIMPL; 670 } 671 672 static HRESULT STDMETHODCALLTYPE debugclient_GetOutputLinePrefix(IDebugClient7 *iface, char *buffer, ULONG buffer_size, 673 ULONG *prefix_size) 674 { 675 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, prefix_size); 676 677 return E_NOTIMPL; 678 } 679 680 static HRESULT STDMETHODCALLTYPE debugclient_SetOutputLinePrefix(IDebugClient7 *iface, const char *prefix) 681 { 682 FIXME("%p, %s stub.\n", iface, debugstr_a(prefix)); 683 684 return E_NOTIMPL; 685 } 686 687 static HRESULT STDMETHODCALLTYPE debugclient_GetIdentity(IDebugClient7 *iface, char *buffer, ULONG buffer_size, 688 ULONG *identity_size) 689 { 690 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, identity_size); 691 692 return E_NOTIMPL; 693 } 694 695 static HRESULT STDMETHODCALLTYPE debugclient_OutputIdentity(IDebugClient7 *iface, ULONG output_control, ULONG flags, 696 const char *format) 697 { 698 FIXME("%p, %u, %#x, %s stub.\n", iface, output_control, flags, debugstr_a(format)); 699 700 return E_NOTIMPL; 701 } 702 703 static HRESULT STDMETHODCALLTYPE debugclient_GetEventCallbacks(IDebugClient7 *iface, IDebugEventCallbacks **callbacks) 704 { 705 struct debug_client *debug_client = impl_from_IDebugClient(iface); 706 707 TRACE("%p, %p.\n", iface, callbacks); 708 709 if (debug_client->event_callbacks) 710 { 711 *callbacks = debug_client->event_callbacks; 712 (*callbacks)->lpVtbl->AddRef(*callbacks); 713 } 714 715 return S_OK; 716 } 717 718 static HRESULT STDMETHODCALLTYPE debugclient_SetEventCallbacks(IDebugClient7 *iface, IDebugEventCallbacks *callbacks) 719 { 720 struct debug_client *debug_client = impl_from_IDebugClient(iface); 721 722 TRACE("%p, %p.\n", iface, callbacks); 723 724 if (debug_client->event_callbacks) 725 debug_client->event_callbacks->lpVtbl->Release(debug_client->event_callbacks); 726 if ((debug_client->event_callbacks = callbacks)) 727 debug_client->event_callbacks->lpVtbl->AddRef(debug_client->event_callbacks); 728 729 return S_OK; 730 } 731 732 static HRESULT STDMETHODCALLTYPE debugclient_FlushCallbacks(IDebugClient7 *iface) 733 { 734 FIXME("%p stub.\n", iface); 735 736 return E_NOTIMPL; 737 } 738 739 static HRESULT STDMETHODCALLTYPE debugclient_WriteDumpFile2(IDebugClient7 *iface, const char *dumpfile, ULONG qualifier, 740 ULONG flags, const char *comment) 741 { 742 FIXME("%p, %s, %d, 0x%08x, %s.\n", iface, debugstr_a(dumpfile), qualifier, flags, debugstr_a(comment)); 743 return E_NOTIMPL; 744 } 745 746 static HRESULT STDMETHODCALLTYPE debugclient_AddDumpInformationFile(IDebugClient7 *iface, const char *infofile, ULONG type) 747 { 748 FIXME("%p, %s, %d.\n", iface, debugstr_a(infofile), type); 749 return E_NOTIMPL; 750 } 751 752 static HRESULT STDMETHODCALLTYPE debugclient_EndProcessServer(IDebugClient7 *iface, ULONG64 server) 753 { 754 FIXME("%p, %s.\n", iface, wine_dbgstr_longlong(server)); 755 return E_NOTIMPL; 756 } 757 758 static HRESULT STDMETHODCALLTYPE debugclient_WaitForProcessServerEnd(IDebugClient7 *iface, ULONG timeout) 759 { 760 FIXME("%p, %d.\n", iface, timeout); 761 return E_NOTIMPL; 762 } 763 764 static HRESULT STDMETHODCALLTYPE debugclient_IsKernelDebuggerEnabled(IDebugClient7 *iface) 765 { 766 FIXME("%p.\n", iface); 767 return E_NOTIMPL; 768 } 769 770 static HRESULT STDMETHODCALLTYPE debugclient_TerminateCurrentProcess(IDebugClient7 *iface) 771 { 772 FIXME("%p.\n", iface); 773 return E_NOTIMPL; 774 } 775 776 static HRESULT STDMETHODCALLTYPE debugclient_DetachCurrentProcess(IDebugClient7 *iface) 777 { 778 FIXME("%p.\n", iface); 779 return E_NOTIMPL; 780 } 781 782 static HRESULT STDMETHODCALLTYPE debugclient_AbandonCurrentProcess(IDebugClient7 *iface) 783 { 784 FIXME("%p.\n", iface); 785 return E_NOTIMPL; 786 } 787 788 static HRESULT STDMETHODCALLTYPE debugclient_GetRunningProcessSystemIdByExecutableNameWide(IDebugClient7 *iface, ULONG64 server, 789 const WCHAR *exename, ULONG flags, ULONG *id) 790 { 791 FIXME("%p, %s, %s, 0x%08x, %p.\n", iface, wine_dbgstr_longlong(server), debugstr_w(exename), flags, id); 792 return E_NOTIMPL; 793 } 794 795 static HRESULT STDMETHODCALLTYPE debugclient_GetRunningProcessDescriptionWide(IDebugClient7 *iface, ULONG64 server, ULONG id, 796 ULONG flags, WCHAR *exename, ULONG size, ULONG *actualsize, WCHAR *description, ULONG desc_size, ULONG *actual_desc_size) 797 { 798 FIXME("%p, %s, %d, 0x%08x, %s, %d, %p, %s, %d, %p.\n", iface, wine_dbgstr_longlong(server), id, flags, debugstr_w(exename), size, 799 actualsize, debugstr_w(description), desc_size, actual_desc_size ); 800 return E_NOTIMPL; 801 } 802 803 static HRESULT STDMETHODCALLTYPE debugclient_CreateProcessWide(IDebugClient7 *iface, ULONG64 server, WCHAR *commandline, ULONG flags) 804 { 805 FIXME("%p, %s, %s, 0x%08x.\n", iface, wine_dbgstr_longlong(server), debugstr_w(commandline), flags); 806 return E_NOTIMPL; 807 } 808 809 static HRESULT STDMETHODCALLTYPE debugclient_CreateProcessAndAttachWide(IDebugClient7 *iface, ULONG64 server, WCHAR *commandline, 810 ULONG flags, ULONG processid, ULONG attachflags) 811 { 812 FIXME("%p, %s, %s, 0x%08x, %d, 0x%08x.\n", iface, wine_dbgstr_longlong(server), debugstr_w(commandline), flags, processid, attachflags); 813 return E_NOTIMPL; 814 } 815 816 static HRESULT STDMETHODCALLTYPE debugclient_OpenDumpFileWide(IDebugClient7 *iface, const WCHAR *filename, ULONG64 handle) 817 { 818 FIXME("%p, %s, %s.\n", iface, debugstr_w(filename), wine_dbgstr_longlong(handle)); 819 return E_NOTIMPL; 820 } 821 822 static HRESULT STDMETHODCALLTYPE debugclient_WriteDumpFileWide(IDebugClient7 *iface, const WCHAR *filename, ULONG64 handle, 823 ULONG qualifier, ULONG flags, const WCHAR *comment) 824 { 825 FIXME("%p, %s, %s, %d, 0x%08x, %s.\n", iface, debugstr_w(filename), wine_dbgstr_longlong(handle), 826 qualifier, flags, debugstr_w(comment)); 827 return E_NOTIMPL; 828 } 829 830 static HRESULT STDMETHODCALLTYPE debugclient_AddDumpInformationFileWide(IDebugClient7 *iface, const WCHAR *filename, 831 ULONG64 handle, ULONG type) 832 { 833 FIXME("%p, %s, %s, %d.\n", iface, debugstr_w(filename), wine_dbgstr_longlong(handle), type); 834 return E_NOTIMPL; 835 } 836 837 static HRESULT STDMETHODCALLTYPE debugclient_GetNumberDumpFiles(IDebugClient7 *iface, ULONG *count) 838 { 839 FIXME("%p, %p.\n", iface, count); 840 return E_NOTIMPL; 841 } 842 843 static HRESULT STDMETHODCALLTYPE debugclient_GetDumpFile(IDebugClient7 *iface, ULONG index, char *buffer, ULONG buf_size, 844 ULONG *name_size, ULONG64 *handle, ULONG *type) 845 { 846 FIXME("%p, %d, %p, %d, %p, %p, %p.\n", iface, index, buffer, buf_size, name_size, handle, type); 847 return E_NOTIMPL; 848 } 849 850 static HRESULT STDMETHODCALLTYPE debugclient_GetDumpFileWide(IDebugClient7 *iface, ULONG index, WCHAR *buffer, ULONG buf_size, 851 ULONG *name_size, ULONG64 *handle, ULONG *type) 852 { 853 FIXME("%p, %d, %p, %d, %p, %p, %p.\n", iface, index, buffer, buf_size, name_size, handle, type); 854 return E_NOTIMPL; 855 } 856 857 static HRESULT STDMETHODCALLTYPE debugclient_AttachKernelWide(IDebugClient7 *iface, ULONG flags, const WCHAR *options) 858 { 859 FIXME("%p, 0x%08x, %s.\n", iface, flags, debugstr_w(options)); 860 return E_NOTIMPL; 861 } 862 863 static HRESULT STDMETHODCALLTYPE debugclient_GetKernelConnectionOptionsWide(IDebugClient7 *iface, WCHAR *buffer, 864 ULONG buf_size, ULONG *size) 865 { 866 FIXME("%p, %p, %d, %p.\n", iface, buffer, buf_size, size); 867 return E_NOTIMPL; 868 } 869 870 static HRESULT STDMETHODCALLTYPE debugclient_SetKernelConnectionOptionsWide(IDebugClient7 *iface, const WCHAR *options) 871 { 872 FIXME("%p, %p.\n", iface, options); 873 return E_NOTIMPL; 874 } 875 876 static HRESULT STDMETHODCALLTYPE debugclient_StartProcessServerWide(IDebugClient7 *iface, ULONG flags, const WCHAR *options, void *reserved) 877 { 878 FIXME("%p, 0x%08x, %s, %p.\n", iface, flags, debugstr_w(options), reserved); 879 return E_NOTIMPL; 880 } 881 882 static HRESULT STDMETHODCALLTYPE debugclient_ConnectProcessServerWide(IDebugClient7 *iface, const WCHAR *options, ULONG64 *server) 883 { 884 FIXME("%p, %s, %p.\n", iface, debugstr_w(options), server); 885 return E_NOTIMPL; 886 } 887 888 static HRESULT STDMETHODCALLTYPE debugclient_StartServerWide(IDebugClient7 *iface, const WCHAR *options) 889 { 890 FIXME("%p, %s.\n", iface, debugstr_w(options)); 891 return E_NOTIMPL; 892 } 893 894 static HRESULT STDMETHODCALLTYPE debugclient_OutputServersWide(IDebugClient7 *iface, ULONG control, const WCHAR *machine, ULONG flags) 895 { 896 FIXME("%p, %d, %s, 0x%08x.\n", iface, control, debugstr_w(machine), flags); 897 return E_NOTIMPL; 898 } 899 900 static HRESULT STDMETHODCALLTYPE debugclient_GetOutputCallbacksWide(IDebugClient7 *iface, IDebugOutputCallbacksWide **callbacks) 901 { 902 FIXME("%p, %p.\n", iface, callbacks); 903 return E_NOTIMPL; 904 } 905 906 static HRESULT STDMETHODCALLTYPE debugclient_SetOutputCallbacksWide(IDebugClient7 *iface, IDebugOutputCallbacksWide *callbacks) 907 { 908 FIXME("%p, %p.\n", iface, callbacks); 909 return E_NOTIMPL; 910 } 911 912 static HRESULT STDMETHODCALLTYPE debugclient_GetOutputLinePrefixWide(IDebugClient7 *iface, WCHAR *buffer, ULONG buf_size, ULONG *size) 913 { 914 FIXME("%p, %p, %d, %p.\n", iface, buffer, buf_size, size); 915 return E_NOTIMPL; 916 } 917 918 static HRESULT STDMETHODCALLTYPE debugclient_SetOutputLinePrefixWide(IDebugClient7 *iface, const WCHAR *prefix) 919 { 920 FIXME("%p, %s.\n", iface, debugstr_w(prefix)); 921 return E_NOTIMPL; 922 } 923 924 static HRESULT STDMETHODCALLTYPE debugclient_GetIdentityWide(IDebugClient7 *iface, WCHAR *buffer, ULONG buf_size, ULONG *identity) 925 { 926 FIXME("%p, %p, %d, %p.\n", iface, buffer, buf_size, identity); 927 return E_NOTIMPL; 928 } 929 930 static HRESULT STDMETHODCALLTYPE debugclient_OutputIdentityWide(IDebugClient7 *iface, ULONG control, ULONG flags, const WCHAR *format) 931 { 932 FIXME("%p, %d, 0x%08x, %s.\n", iface, control, flags, debugstr_w(format)); 933 return E_NOTIMPL; 934 } 935 936 static HRESULT STDMETHODCALLTYPE debugclient_GetEventCallbacksWide(IDebugClient7 *iface, IDebugEventCallbacksWide **callbacks) 937 { 938 FIXME("%p, %p .\n", iface, callbacks); 939 return E_NOTIMPL; 940 } 941 942 static HRESULT STDMETHODCALLTYPE debugclient_SetEventCallbacksWide(IDebugClient7 *iface, IDebugEventCallbacksWide *callbacks) 943 { 944 FIXME("%p .\n", iface); 945 return E_NOTIMPL; 946 } 947 948 static HRESULT STDMETHODCALLTYPE debugclient_CreateProcess2(IDebugClient7 *iface, ULONG64 server, char *command, void *options, 949 ULONG buf_size, const char *initial, const char *environment) 950 { 951 FIXME("%p %s, %s, %p, %d, %s, %s.\n", iface, wine_dbgstr_longlong(server), debugstr_a(command), options, 952 buf_size, debugstr_a(initial), debugstr_a(environment)); 953 return E_NOTIMPL; 954 } 955 956 static HRESULT STDMETHODCALLTYPE debugclient_CreateProcess2Wide(IDebugClient7 *iface, ULONG64 server, WCHAR *command, void *options, 957 ULONG size, const WCHAR *initial, const WCHAR *environment) 958 { 959 FIXME("%p %s, %s, %p, %d, %s, %s.\n", iface, wine_dbgstr_longlong(server), debugstr_w(command), options, 960 size, debugstr_w(initial), debugstr_w(environment)); 961 return E_NOTIMPL; 962 } 963 964 static HRESULT STDMETHODCALLTYPE debugclient_CreateProcessAndAttach2(IDebugClient7 *iface, ULONG64 server, char *command, 965 void *options, ULONG buf_size, const char *initial, const char *environment, ULONG processid, ULONG flags) 966 { 967 FIXME("%p %s, %s, %p, %d, %s, %s, %d, 0x%08x.\n", iface, wine_dbgstr_longlong(server), debugstr_a(command), options, 968 buf_size, debugstr_a(initial), debugstr_a(environment), processid, flags); 969 return E_NOTIMPL; 970 } 971 972 static HRESULT STDMETHODCALLTYPE debugclient_CreateProcessAndAttach2Wide(IDebugClient7 *iface, ULONG64 server, WCHAR *command, 973 void *buffer, ULONG buf_size, const WCHAR *initial, const WCHAR *environment, ULONG processid, ULONG flags) 974 { 975 FIXME("%p %s, %s, %p, %d, %s, %s, %d, 0x%08x.\n", iface, wine_dbgstr_longlong(server), debugstr_w(command), buffer, 976 buf_size, debugstr_w(initial), debugstr_w(environment), processid, flags); 977 return E_NOTIMPL; 978 } 979 980 static HRESULT STDMETHODCALLTYPE debugclient_PushOutputLinePrefix(IDebugClient7 *iface, const char *prefix, ULONG64 *handle) 981 { 982 FIXME("%p, %p.\n", iface, handle); 983 return E_NOTIMPL; 984 } 985 986 static HRESULT STDMETHODCALLTYPE debugclient_PushOutputLinePrefixWide(IDebugClient7 *iface, const WCHAR *prefix, ULONG64 *handle) 987 { 988 FIXME("%p, %p.\n", iface, handle); 989 return E_NOTIMPL; 990 } 991 992 static HRESULT STDMETHODCALLTYPE debugclient_PopOutputLinePrefix(IDebugClient7 *iface, ULONG64 handle) 993 { 994 FIXME("%p, %s.\n", iface, wine_dbgstr_longlong(handle)); 995 return E_NOTIMPL; 996 } 997 998 static HRESULT STDMETHODCALLTYPE debugclient_GetNumberInputCallbacks(IDebugClient7 *iface, ULONG *count) 999 { 1000 FIXME("%p, %p.\n", iface, count); 1001 return E_NOTIMPL; 1002 } 1003 1004 static HRESULT STDMETHODCALLTYPE debugclient_GetNumberOutputCallbacks(IDebugClient7 *iface, ULONG *count) 1005 { 1006 FIXME("%p, %p.\n", iface, count); 1007 return E_NOTIMPL; 1008 } 1009 1010 static HRESULT STDMETHODCALLTYPE debugclient_GetNumberEventCallbacks(IDebugClient7 *iface, ULONG flags, ULONG *count) 1011 { 1012 FIXME("%p, 0x%08x, %p.\n", iface, flags, count); 1013 return E_NOTIMPL; 1014 } 1015 1016 static HRESULT STDMETHODCALLTYPE debugclient_GetQuitLockString(IDebugClient7 *iface, char *buffer, ULONG buf_size, ULONG *size) 1017 { 1018 FIXME("%p, %s, %d, %p.\n", iface, debugstr_a(buffer), buf_size, size); 1019 return E_NOTIMPL; 1020 } 1021 1022 static HRESULT STDMETHODCALLTYPE debugclient_SetQuitLockString(IDebugClient7 *iface, char *string) 1023 { 1024 FIXME("%p, %s.\n", iface, debugstr_a(string)); 1025 return E_NOTIMPL; 1026 } 1027 1028 static HRESULT STDMETHODCALLTYPE debugclient_GetQuitLockStringWide(IDebugClient7 *iface, WCHAR *buffer, ULONG buf_size, ULONG *size) 1029 { 1030 FIXME("%p, %s, %d, %p.\n", iface, debugstr_w(buffer), buf_size, size); 1031 return E_NOTIMPL; 1032 } 1033 1034 static HRESULT STDMETHODCALLTYPE debugclient_SetQuitLockStringWide(IDebugClient7 *iface, const WCHAR *string) 1035 { 1036 FIXME("%p, %s.\n", iface, debugstr_w(string)); 1037 return E_NOTIMPL; 1038 } 1039 1040 static HRESULT STDMETHODCALLTYPE debugclient_SetEventContextCallbacks(IDebugClient7 *iface, IDebugEventContextCallbacks *callbacks) 1041 { 1042 FIXME("%p, %p.\n", iface, callbacks); 1043 return E_NOTIMPL; 1044 } 1045 1046 static HRESULT STDMETHODCALLTYPE debugclient_SetClientContext(IDebugClient7 *iface, void *context, ULONG size) 1047 { 1048 FIXME("%p, %p, %d.\n", iface, context, size); 1049 return E_NOTIMPL; 1050 } 1051 1052 static const IDebugClient7Vtbl debugclientvtbl = 1053 { 1054 debugclient_QueryInterface, 1055 debugclient_AddRef, 1056 debugclient_Release, 1057 debugclient_AttachKernel, 1058 debugclient_GetKernelConnectionOptions, 1059 debugclient_SetKernelConnectionOptions, 1060 debugclient_StartProcessServer, 1061 debugclient_ConnectProcessServer, 1062 debugclient_DisconnectProcessServer, 1063 debugclient_GetRunningProcessSystemIds, 1064 debugclient_GetRunningProcessSystemIdByExecutableName, 1065 debugclient_GetRunningProcessDescription, 1066 debugclient_AttachProcess, 1067 debugclient_CreateProcess, 1068 debugclient_CreateProcessAndAttach, 1069 debugclient_GetProcessOptions, 1070 debugclient_AddProcessOptions, 1071 debugclient_RemoveProcessOptions, 1072 debugclient_SetProcessOptions, 1073 debugclient_OpenDumpFile, 1074 debugclient_WriteDumpFile, 1075 debugclient_ConnectSession, 1076 debugclient_StartServer, 1077 debugclient_OutputServers, 1078 debugclient_TerminateProcesses, 1079 debugclient_DetachProcesses, 1080 debugclient_EndSession, 1081 debugclient_GetExitCode, 1082 debugclient_DispatchCallbacks, 1083 debugclient_ExitDispatch, 1084 debugclient_CreateClient, 1085 debugclient_GetInputCallbacks, 1086 debugclient_SetInputCallbacks, 1087 debugclient_GetOutputCallbacks, 1088 debugclient_SetOutputCallbacks, 1089 debugclient_GetOutputMask, 1090 debugclient_SetOutputMask, 1091 debugclient_GetOtherOutputMask, 1092 debugclient_SetOtherOutputMask, 1093 debugclient_GetOutputWidth, 1094 debugclient_SetOutputWidth, 1095 debugclient_GetOutputLinePrefix, 1096 debugclient_SetOutputLinePrefix, 1097 debugclient_GetIdentity, 1098 debugclient_OutputIdentity, 1099 debugclient_GetEventCallbacks, 1100 debugclient_SetEventCallbacks, 1101 debugclient_FlushCallbacks, 1102 /* IDebugClient2 */ 1103 debugclient_WriteDumpFile2, 1104 debugclient_AddDumpInformationFile, 1105 debugclient_EndProcessServer, 1106 debugclient_WaitForProcessServerEnd, 1107 debugclient_IsKernelDebuggerEnabled, 1108 debugclient_TerminateCurrentProcess, 1109 debugclient_DetachCurrentProcess, 1110 debugclient_AbandonCurrentProcess, 1111 /* IDebugClient3 */ 1112 debugclient_GetRunningProcessSystemIdByExecutableNameWide, 1113 debugclient_GetRunningProcessDescriptionWide, 1114 debugclient_CreateProcessWide, 1115 debugclient_CreateProcessAndAttachWide, 1116 /* IDebugClient4 */ 1117 debugclient_OpenDumpFileWide, 1118 debugclient_WriteDumpFileWide, 1119 debugclient_AddDumpInformationFileWide, 1120 debugclient_GetNumberDumpFiles, 1121 debugclient_GetDumpFile, 1122 debugclient_GetDumpFileWide, 1123 /* IDebugClient5 */ 1124 debugclient_AttachKernelWide, 1125 debugclient_GetKernelConnectionOptionsWide, 1126 debugclient_SetKernelConnectionOptionsWide, 1127 debugclient_StartProcessServerWide, 1128 debugclient_ConnectProcessServerWide, 1129 debugclient_StartServerWide, 1130 debugclient_OutputServersWide, 1131 debugclient_GetOutputCallbacksWide, 1132 debugclient_SetOutputCallbacksWide, 1133 debugclient_GetOutputLinePrefixWide, 1134 debugclient_SetOutputLinePrefixWide, 1135 debugclient_GetIdentityWide, 1136 debugclient_OutputIdentityWide, 1137 debugclient_GetEventCallbacksWide, 1138 debugclient_SetEventCallbacksWide, 1139 debugclient_CreateProcess2, 1140 debugclient_CreateProcess2Wide, 1141 debugclient_CreateProcessAndAttach2, 1142 debugclient_CreateProcessAndAttach2Wide, 1143 debugclient_PushOutputLinePrefix, 1144 debugclient_PushOutputLinePrefixWide, 1145 debugclient_PopOutputLinePrefix, 1146 debugclient_GetNumberInputCallbacks, 1147 debugclient_GetNumberOutputCallbacks, 1148 debugclient_GetNumberEventCallbacks, 1149 debugclient_GetQuitLockString, 1150 debugclient_SetQuitLockString, 1151 debugclient_GetQuitLockStringWide, 1152 debugclient_SetQuitLockStringWide, 1153 /* IDebugClient6 */ 1154 debugclient_SetEventContextCallbacks, 1155 /* IDebugClient7 */ 1156 debugclient_SetClientContext, 1157 }; 1158 1159 static HRESULT STDMETHODCALLTYPE debugdataspaces_QueryInterface(IDebugDataSpaces *iface, REFIID riid, void **obj) 1160 { 1161 struct debug_client *debug_client = impl_from_IDebugDataSpaces(iface); 1162 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 1163 return IUnknown_QueryInterface(unk, riid, obj); 1164 } 1165 1166 static ULONG STDMETHODCALLTYPE debugdataspaces_AddRef(IDebugDataSpaces *iface) 1167 { 1168 struct debug_client *debug_client = impl_from_IDebugDataSpaces(iface); 1169 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 1170 return IUnknown_AddRef(unk); 1171 } 1172 1173 static ULONG STDMETHODCALLTYPE debugdataspaces_Release(IDebugDataSpaces *iface) 1174 { 1175 struct debug_client *debug_client = impl_from_IDebugDataSpaces(iface); 1176 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 1177 return IUnknown_Release(unk); 1178 } 1179 1180 static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadVirtual(IDebugDataSpaces *iface, ULONG64 offset, void *buffer, 1181 ULONG buffer_size, ULONG *read_len) 1182 { 1183 struct debug_client *debug_client = impl_from_IDebugDataSpaces(iface); 1184 static struct target_process *target; 1185 HRESULT hr = S_OK; 1186 SIZE_T length; 1187 1188 TRACE("%p, %s, %p, %u, %p.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, read_len); 1189 1190 if (!(target = debug_client_get_target(debug_client))) 1191 return E_UNEXPECTED; 1192 1193 if (ReadProcessMemory(target->handle, (const void *)(ULONG_PTR)offset, buffer, buffer_size, &length)) 1194 { 1195 if (read_len) 1196 *read_len = length; 1197 } 1198 else 1199 { 1200 hr = HRESULT_FROM_WIN32(GetLastError()); 1201 WARN("Failed to read process memory %#x.\n", hr); 1202 } 1203 1204 return hr; 1205 } 1206 1207 static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteVirtual(IDebugDataSpaces *iface, ULONG64 offset, void *buffer, 1208 ULONG buffer_size, ULONG *written) 1209 { 1210 FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, written); 1211 1212 return E_NOTIMPL; 1213 } 1214 1215 static HRESULT STDMETHODCALLTYPE debugdataspaces_SearchVirtual(IDebugDataSpaces *iface, ULONG64 offset, ULONG64 length, 1216 void *pattern, ULONG pattern_size, ULONG pattern_granularity, ULONG64 *ret_offset) 1217 { 1218 FIXME("%p, %s, %s, %p, %u, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), wine_dbgstr_longlong(length), 1219 pattern, pattern_size, pattern_granularity, ret_offset); 1220 1221 return E_NOTIMPL; 1222 } 1223 1224 static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadVirtualUncached(IDebugDataSpaces *iface, ULONG64 offset, 1225 void *buffer, ULONG buffer_size, ULONG *read_len) 1226 { 1227 FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, read_len); 1228 1229 return E_NOTIMPL; 1230 } 1231 1232 static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteVirtualUncached(IDebugDataSpaces *iface, ULONG64 offset, 1233 void *buffer, ULONG buffer_size, ULONG *written) 1234 { 1235 FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, written); 1236 1237 return E_NOTIMPL; 1238 } 1239 1240 static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadPointersVirtual(IDebugDataSpaces *iface, ULONG count, 1241 ULONG64 offset, ULONG64 *pointers) 1242 { 1243 FIXME("%p, %u, %s, %p stub.\n", iface, count, wine_dbgstr_longlong(offset), pointers); 1244 1245 return E_NOTIMPL; 1246 } 1247 1248 static HRESULT STDMETHODCALLTYPE debugdataspaces_WritePointersVirtual(IDebugDataSpaces *iface, ULONG count, 1249 ULONG64 offset, ULONG64 *pointers) 1250 { 1251 FIXME("%p, %u, %s, %p stub.\n", iface, count, wine_dbgstr_longlong(offset), pointers); 1252 1253 return E_NOTIMPL; 1254 } 1255 1256 static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadPhysical(IDebugDataSpaces *iface, ULONG64 offset, void *buffer, 1257 ULONG buffer_size, ULONG *read_len) 1258 { 1259 FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, read_len); 1260 1261 return E_NOTIMPL; 1262 } 1263 1264 static HRESULT STDMETHODCALLTYPE debugdataspaces_WritePhysical(IDebugDataSpaces *iface, ULONG64 offset, void *buffer, 1265 ULONG buffer_size, ULONG *written) 1266 { 1267 FIXME("%p, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, written); 1268 1269 return E_NOTIMPL; 1270 } 1271 1272 static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadControl(IDebugDataSpaces *iface, ULONG processor, ULONG64 offset, 1273 void *buffer, ULONG buffer_size, ULONG *read_len) 1274 { 1275 FIXME("%p, %u, %s, %p, %u, %p stub.\n", iface, processor, wine_dbgstr_longlong(offset), buffer, buffer_size, read_len); 1276 1277 return E_NOTIMPL; 1278 } 1279 1280 static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteControl(IDebugDataSpaces *iface, ULONG processor, ULONG64 offset, 1281 void *buffer, ULONG buffer_size, ULONG *written) 1282 { 1283 FIXME("%p, %u, %s, %p, %u, %p stub.\n", iface, processor, wine_dbgstr_longlong(offset), buffer, buffer_size, written); 1284 1285 return E_NOTIMPL; 1286 } 1287 1288 static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadIo(IDebugDataSpaces *iface, ULONG type, ULONG bus_number, 1289 ULONG address_space, ULONG64 offset, void *buffer, ULONG buffer_size, ULONG *read_len) 1290 { 1291 FIXME("%p, %u, %u, %u, %s, %p, %u, %p stub.\n", iface, type, bus_number, address_space, wine_dbgstr_longlong(offset), 1292 buffer, buffer_size, read_len); 1293 1294 return E_NOTIMPL; 1295 } 1296 1297 static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteIo(IDebugDataSpaces *iface, ULONG type, ULONG bus_number, 1298 ULONG address_space, ULONG64 offset, void *buffer, ULONG buffer_size, ULONG *written) 1299 { 1300 FIXME("%p, %u, %u, %u, %s, %p, %u, %p stub.\n", iface, type, bus_number, address_space, wine_dbgstr_longlong(offset), 1301 buffer, buffer_size, written); 1302 1303 return E_NOTIMPL; 1304 } 1305 1306 static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadMsr(IDebugDataSpaces *iface, ULONG msr, ULONG64 *value) 1307 { 1308 FIXME("%p, %u, %p stub.\n", iface, msr, value); 1309 1310 return E_NOTIMPL; 1311 } 1312 1313 static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteMsr(IDebugDataSpaces *iface, ULONG msr, ULONG64 value) 1314 { 1315 FIXME("%p, %u, %s stub.\n", iface, msr, wine_dbgstr_longlong(value)); 1316 1317 return E_NOTIMPL; 1318 } 1319 1320 static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadBusData(IDebugDataSpaces *iface, ULONG data_type, 1321 ULONG bus_number, ULONG slot_number, ULONG offset, void *buffer, ULONG buffer_size, ULONG *read_len) 1322 { 1323 FIXME("%p, %u, %u, %u, %u, %p, %u, %p stub.\n", iface, data_type, bus_number, slot_number, offset, buffer, 1324 buffer_size, read_len); 1325 1326 return E_NOTIMPL; 1327 } 1328 1329 static HRESULT STDMETHODCALLTYPE debugdataspaces_WriteBusData(IDebugDataSpaces *iface, ULONG data_type, 1330 ULONG bus_number, ULONG slot_number, ULONG offset, void *buffer, ULONG buffer_size, ULONG *written) 1331 { 1332 FIXME("%p, %u, %u, %u, %u, %p, %u, %p stub.\n", iface, data_type, bus_number, slot_number, offset, buffer, 1333 buffer_size, written); 1334 1335 return E_NOTIMPL; 1336 } 1337 1338 static HRESULT STDMETHODCALLTYPE debugdataspaces_CheckLowMemory(IDebugDataSpaces *iface) 1339 { 1340 FIXME("%p stub.\n", iface); 1341 1342 return E_NOTIMPL; 1343 } 1344 1345 static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadDebuggerData(IDebugDataSpaces *iface, ULONG index, void *buffer, 1346 ULONG buffer_size, ULONG *data_size) 1347 { 1348 FIXME("%p, %u, %p, %u, %p stub.\n", iface, index, buffer, buffer_size, data_size); 1349 1350 return E_NOTIMPL; 1351 } 1352 1353 static HRESULT STDMETHODCALLTYPE debugdataspaces_ReadProcessorSystemData(IDebugDataSpaces *iface, ULONG processor, 1354 ULONG index, void *buffer, ULONG buffer_size, ULONG *data_size) 1355 { 1356 FIXME("%p, %u, %u, %p, %u, %p stub.\n", iface, processor, index, buffer, buffer_size, data_size); 1357 1358 return E_NOTIMPL; 1359 } 1360 1361 static const IDebugDataSpacesVtbl debugdataspacesvtbl = 1362 { 1363 debugdataspaces_QueryInterface, 1364 debugdataspaces_AddRef, 1365 debugdataspaces_Release, 1366 debugdataspaces_ReadVirtual, 1367 debugdataspaces_WriteVirtual, 1368 debugdataspaces_SearchVirtual, 1369 debugdataspaces_ReadVirtualUncached, 1370 debugdataspaces_WriteVirtualUncached, 1371 debugdataspaces_ReadPointersVirtual, 1372 debugdataspaces_WritePointersVirtual, 1373 debugdataspaces_ReadPhysical, 1374 debugdataspaces_WritePhysical, 1375 debugdataspaces_ReadControl, 1376 debugdataspaces_WriteControl, 1377 debugdataspaces_ReadIo, 1378 debugdataspaces_WriteIo, 1379 debugdataspaces_ReadMsr, 1380 debugdataspaces_WriteMsr, 1381 debugdataspaces_ReadBusData, 1382 debugdataspaces_WriteBusData, 1383 debugdataspaces_CheckLowMemory, 1384 debugdataspaces_ReadDebuggerData, 1385 debugdataspaces_ReadProcessorSystemData, 1386 }; 1387 1388 static HRESULT STDMETHODCALLTYPE debugsymbols_QueryInterface(IDebugSymbols3 *iface, REFIID riid, void **obj) 1389 { 1390 struct debug_client *debug_client = impl_from_IDebugSymbols3(iface); 1391 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 1392 return IUnknown_QueryInterface(unk, riid, obj); 1393 } 1394 1395 static ULONG STDMETHODCALLTYPE debugsymbols_AddRef(IDebugSymbols3 *iface) 1396 { 1397 struct debug_client *debug_client = impl_from_IDebugSymbols3(iface); 1398 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 1399 return IUnknown_AddRef(unk); 1400 } 1401 1402 static ULONG STDMETHODCALLTYPE debugsymbols_Release(IDebugSymbols3 *iface) 1403 { 1404 struct debug_client *debug_client = impl_from_IDebugSymbols3(iface); 1405 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 1406 return IUnknown_Release(unk); 1407 } 1408 1409 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolOptions(IDebugSymbols3 *iface, ULONG *options) 1410 { 1411 FIXME("%p, %p stub.\n", iface, options); 1412 1413 return E_NOTIMPL; 1414 } 1415 1416 static HRESULT STDMETHODCALLTYPE debugsymbols_AddSymbolOptions(IDebugSymbols3 *iface, ULONG options) 1417 { 1418 FIXME("%p, %#x stub.\n", iface, options); 1419 1420 return E_NOTIMPL; 1421 } 1422 1423 static HRESULT STDMETHODCALLTYPE debugsymbols_RemoveSymbolOptions(IDebugSymbols3 *iface, ULONG options) 1424 { 1425 FIXME("%p, %#x stub.\n", iface, options); 1426 1427 return E_NOTIMPL; 1428 } 1429 1430 static HRESULT STDMETHODCALLTYPE debugsymbols_SetSymbolOptions(IDebugSymbols3 *iface, ULONG options) 1431 { 1432 FIXME("%p, %#x stub.\n", iface, options); 1433 1434 return E_NOTIMPL; 1435 } 1436 1437 static HRESULT STDMETHODCALLTYPE debugsymbols_GetNameByOffset(IDebugSymbols3 *iface, ULONG64 offset, char *buffer, 1438 ULONG buffer_size, ULONG *name_size, ULONG64 *displacement) 1439 { 1440 FIXME("%p, %s, %p, %u, %p, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, 1441 name_size, displacement); 1442 1443 return E_NOTIMPL; 1444 } 1445 1446 static HRESULT STDMETHODCALLTYPE debugsymbols_GetOffsetByName(IDebugSymbols3 *iface, const char *symbol, 1447 ULONG64 *offset) 1448 { 1449 FIXME("%p, %s, %p stub.\n", iface, debugstr_a(symbol), offset); 1450 1451 return E_NOTIMPL; 1452 } 1453 1454 static HRESULT STDMETHODCALLTYPE debugsymbols_GetNearNameByOffset(IDebugSymbols3 *iface, ULONG64 offset, LONG delta, 1455 char *buffer, ULONG buffer_size, ULONG *name_size, ULONG64 *displacement) 1456 { 1457 FIXME("%p, %s, %d, %p, %u, %p, %p stub.\n", iface, wine_dbgstr_longlong(offset), delta, buffer, buffer_size, 1458 name_size, displacement); 1459 1460 return E_NOTIMPL; 1461 } 1462 1463 static HRESULT STDMETHODCALLTYPE debugsymbols_GetLineByOffset(IDebugSymbols3 *iface, ULONG64 offset, ULONG *line, 1464 char *buffer, ULONG buffer_size, ULONG *file_size, ULONG64 *displacement) 1465 { 1466 FIXME("%p, %s, %p, %p, %u, %p, %p stub.\n", iface, wine_dbgstr_longlong(offset), line, buffer, buffer_size, 1467 file_size, displacement); 1468 1469 return E_NOTIMPL; 1470 } 1471 1472 static HRESULT STDMETHODCALLTYPE debugsymbols_GetOffsetByLine(IDebugSymbols3 *iface, ULONG line, const char *file, 1473 ULONG64 *offset) 1474 { 1475 FIXME("%p, %u, %s, %p stub.\n", iface, line, debugstr_a(file), offset); 1476 1477 return E_NOTIMPL; 1478 } 1479 1480 static HRESULT STDMETHODCALLTYPE debugsymbols_GetNumberModules(IDebugSymbols3 *iface, ULONG *loaded, ULONG *unloaded) 1481 { 1482 struct debug_client *debug_client = impl_from_IDebugSymbols3(iface); 1483 static struct target_process *target; 1484 HRESULT hr; 1485 1486 TRACE("%p, %p, %p.\n", iface, loaded, unloaded); 1487 1488 if (!(target = debug_client_get_target(debug_client))) 1489 return E_UNEXPECTED; 1490 1491 if (FAILED(hr = debug_target_init_modules_info(target))) 1492 return hr; 1493 1494 *loaded = target->modules.loaded; 1495 *unloaded = target->modules.unloaded; 1496 1497 return S_OK; 1498 } 1499 1500 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleByIndex(IDebugSymbols3 *iface, ULONG index, ULONG64 *base) 1501 { 1502 struct debug_client *debug_client = impl_from_IDebugSymbols3(iface); 1503 const struct module_info *info; 1504 struct target_process *target; 1505 1506 TRACE("%p, %u, %p.\n", iface, index, base); 1507 1508 if (!(target = debug_client_get_target(debug_client))) 1509 return E_UNEXPECTED; 1510 1511 if (!(info = debug_target_get_module_info(target, index))) 1512 return E_INVALIDARG; 1513 1514 *base = info->params.Base; 1515 1516 return S_OK; 1517 } 1518 1519 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleByModuleName(IDebugSymbols3 *iface, const char *name, 1520 ULONG start_index, ULONG *index, ULONG64 *base) 1521 { 1522 FIXME("%p, %s, %u, %p, %p stub.\n", iface, debugstr_a(name), start_index, index, base); 1523 1524 return E_NOTIMPL; 1525 } 1526 1527 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleByOffset(IDebugSymbols3 *iface, ULONG64 offset, 1528 ULONG start_index, ULONG *index, ULONG64 *base) 1529 { 1530 struct debug_client *debug_client = impl_from_IDebugSymbols3(iface); 1531 static struct target_process *target; 1532 const struct module_info *info; 1533 1534 TRACE("%p, %s, %u, %p, %p.\n", iface, wine_dbgstr_longlong(offset), start_index, index, base); 1535 1536 if (!(target = debug_client_get_target(debug_client))) 1537 return E_UNEXPECTED; 1538 1539 while ((info = debug_target_get_module_info(target, start_index))) 1540 { 1541 if (offset >= info->params.Base && offset < info->params.Base + info->params.Size) 1542 { 1543 if (index) 1544 *index = start_index; 1545 if (base) 1546 *base = info->params.Base; 1547 return S_OK; 1548 } 1549 1550 start_index++; 1551 } 1552 1553 return E_INVALIDARG; 1554 } 1555 1556 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleNames(IDebugSymbols3 *iface, ULONG index, ULONG64 base, 1557 char *image_name, ULONG image_name_buffer_size, ULONG *image_name_size, char *module_name, 1558 ULONG module_name_buffer_size, ULONG *module_name_size, char *loaded_image_name, 1559 ULONG loaded_image_name_buffer_size, ULONG *loaded_image_size) 1560 { 1561 FIXME("%p, %u, %s, %p, %u, %p, %p, %u, %p, %p, %u, %p stub.\n", iface, index, wine_dbgstr_longlong(base), 1562 image_name, image_name_buffer_size, image_name_size, module_name, module_name_buffer_size, 1563 module_name_size, loaded_image_name, loaded_image_name_buffer_size, loaded_image_size); 1564 1565 return E_NOTIMPL; 1566 } 1567 1568 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleParameters(IDebugSymbols3 *iface, ULONG count, ULONG64 *bases, 1569 ULONG start, DEBUG_MODULE_PARAMETERS *params) 1570 { 1571 struct debug_client *debug_client = impl_from_IDebugSymbols3(iface); 1572 const struct module_info *info; 1573 struct target_process *target; 1574 unsigned int i; 1575 1576 TRACE("%p, %u, %p, %u, %p.\n", iface, count, bases, start, params); 1577 1578 if (!(target = debug_client_get_target(debug_client))) 1579 return E_UNEXPECTED; 1580 1581 if (bases) 1582 { 1583 for (i = 0; i < count; ++i) 1584 { 1585 if ((info = debug_target_get_module_info_by_base(target, bases[i]))) 1586 { 1587 params[i] = info->params; 1588 } 1589 else 1590 { 1591 memset(¶ms[i], 0, sizeof(*params)); 1592 params[i].Base = DEBUG_INVALID_OFFSET; 1593 } 1594 } 1595 } 1596 else 1597 { 1598 for (i = start; i < start + count; ++i) 1599 { 1600 if (!(info = debug_target_get_module_info(target, i))) 1601 return E_INVALIDARG; 1602 params[i] = info->params; 1603 } 1604 } 1605 1606 return S_OK; 1607 } 1608 1609 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolModule(IDebugSymbols3 *iface, const char *symbol, ULONG64 *base) 1610 { 1611 FIXME("%p, %s, %p stub.\n", iface, debugstr_a(symbol), base); 1612 1613 return E_NOTIMPL; 1614 } 1615 1616 static HRESULT STDMETHODCALLTYPE debugsymbols_GetTypeName(IDebugSymbols3 *iface, ULONG64 base, ULONG type_id, 1617 char *buffer, ULONG buffer_size, ULONG *name_size) 1618 { 1619 FIXME("%p, %s, %u, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(base), type_id, buffer, 1620 buffer_size, name_size); 1621 1622 return E_NOTIMPL; 1623 } 1624 1625 static HRESULT STDMETHODCALLTYPE debugsymbols_GetTypeId(IDebugSymbols3 *iface, ULONG64 base, const char *name, 1626 ULONG *type_id) 1627 { 1628 FIXME("%p, %s, %s, %p stub.\n", iface, wine_dbgstr_longlong(base), debugstr_a(name), type_id); 1629 1630 return E_NOTIMPL; 1631 } 1632 1633 static HRESULT STDMETHODCALLTYPE debugsymbols_GetTypeSize(IDebugSymbols3 *iface, ULONG64 base, ULONG type_id, 1634 ULONG *size) 1635 { 1636 FIXME("%p, %s, %u, %p stub.\n", iface, wine_dbgstr_longlong(base), type_id, size); 1637 1638 return E_NOTIMPL; 1639 } 1640 1641 static HRESULT STDMETHODCALLTYPE debugsymbols_GetFieldOffset(IDebugSymbols3 *iface, ULONG64 base, ULONG type_id, 1642 const char *field, ULONG *offset) 1643 { 1644 FIXME("%p, %s, %u, %s, %p stub.\n", iface, wine_dbgstr_longlong(base), type_id, debugstr_a(field), offset); 1645 1646 return E_NOTIMPL; 1647 } 1648 1649 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolTypeId(IDebugSymbols3 *iface, const char *symbol, ULONG *type_id, 1650 ULONG64 *base) 1651 { 1652 FIXME("%p, %s, %p, %p stub.\n", iface, debugstr_a(symbol), type_id, base); 1653 1654 return E_NOTIMPL; 1655 } 1656 1657 static HRESULT STDMETHODCALLTYPE debugsymbols_GetOffsetTypeId(IDebugSymbols3 *iface, ULONG64 offset, ULONG *type_id, 1658 ULONG64 *base) 1659 { 1660 FIXME("%p, %s, %p, %p stub.\n", iface, wine_dbgstr_longlong(offset), type_id, base); 1661 1662 return E_NOTIMPL; 1663 } 1664 1665 static HRESULT STDMETHODCALLTYPE debugsymbols_ReadTypedDataVirtual(IDebugSymbols3 *iface, ULONG64 offset, ULONG64 base, 1666 ULONG type_id, void *buffer, ULONG buffer_size, ULONG *read_len) 1667 { 1668 FIXME("%p, %s, %s, %u, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), wine_dbgstr_longlong(base), 1669 type_id, buffer, buffer_size, read_len); 1670 1671 return E_NOTIMPL; 1672 } 1673 1674 static HRESULT STDMETHODCALLTYPE debugsymbols_WriteTypedDataVirtual(IDebugSymbols3 *iface, ULONG64 offset, ULONG64 base, 1675 ULONG type_id, void *buffer, ULONG buffer_size, ULONG *written) 1676 { 1677 FIXME("%p, %s, %s, %u, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), wine_dbgstr_longlong(base), 1678 type_id, buffer, buffer_size, written); 1679 1680 return E_NOTIMPL; 1681 } 1682 1683 static HRESULT STDMETHODCALLTYPE debugsymbols_OutputTypedDataVirtual(IDebugSymbols3 *iface, ULONG output_control, 1684 ULONG64 offset, ULONG64 base, ULONG type_id, ULONG flags) 1685 { 1686 FIXME("%p, %#x, %s, %s, %u, %#x stub.\n", iface, output_control, wine_dbgstr_longlong(offset), 1687 wine_dbgstr_longlong(base), type_id, flags); 1688 1689 return E_NOTIMPL; 1690 } 1691 1692 static HRESULT STDMETHODCALLTYPE debugsymbols_ReadTypedDataPhysical(IDebugSymbols3 *iface, ULONG64 offset, ULONG64 base, 1693 ULONG type_id, void *buffer, ULONG buffer_size, ULONG *read_len) 1694 { 1695 FIXME("%p, %s, %s, %u, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), wine_dbgstr_longlong(base), 1696 type_id, buffer, buffer_size, read_len); 1697 1698 return E_NOTIMPL; 1699 } 1700 1701 static HRESULT STDMETHODCALLTYPE debugsymbols_WriteTypedDataPhysical(IDebugSymbols3 *iface, ULONG64 offset, 1702 ULONG64 base, ULONG type_id, void *buffer, ULONG buffer_size, ULONG *written) 1703 { 1704 FIXME("%p, %s, %s, %u, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), wine_dbgstr_longlong(base), 1705 type_id, buffer, buffer_size, written); 1706 1707 return E_NOTIMPL; 1708 } 1709 1710 static HRESULT STDMETHODCALLTYPE debugsymbols_OutputTypedDataPhysical(IDebugSymbols3 *iface, ULONG output_control, 1711 ULONG64 offset, ULONG64 base, ULONG type_id, ULONG flags) 1712 { 1713 FIXME("%p, %#x, %s, %s, %u, %#x stub.\n", iface, output_control, wine_dbgstr_longlong(offset), 1714 wine_dbgstr_longlong(base), type_id, flags); 1715 1716 return E_NOTIMPL; 1717 } 1718 1719 static HRESULT STDMETHODCALLTYPE debugsymbols_GetScope(IDebugSymbols3 *iface, ULONG64 *instr_offset, 1720 DEBUG_STACK_FRAME *frame, void *scope_context, ULONG scope_context_size) 1721 { 1722 FIXME("%p, %p, %p, %p, %u stub.\n", iface, instr_offset, frame, scope_context, scope_context_size); 1723 1724 return E_NOTIMPL; 1725 } 1726 1727 static HRESULT STDMETHODCALLTYPE debugsymbols_SetScope(IDebugSymbols3 *iface, ULONG64 instr_offset, 1728 DEBUG_STACK_FRAME *frame, void *scope_context, ULONG scope_context_size) 1729 { 1730 FIXME("%p, %s, %p, %p, %u stub.\n", iface, wine_dbgstr_longlong(instr_offset), frame, scope_context, 1731 scope_context_size); 1732 1733 return E_NOTIMPL; 1734 } 1735 1736 static HRESULT STDMETHODCALLTYPE debugsymbols_ResetScope(IDebugSymbols3 *iface) 1737 { 1738 FIXME("%p stub.\n", iface); 1739 1740 return E_NOTIMPL; 1741 } 1742 1743 static HRESULT STDMETHODCALLTYPE debugsymbols_GetScopeSymbolGroup(IDebugSymbols3 *iface, ULONG flags, 1744 IDebugSymbolGroup *update, IDebugSymbolGroup **symbols) 1745 { 1746 FIXME("%p, %#x, %p, %p stub.\n", iface, flags, update, symbols); 1747 1748 return E_NOTIMPL; 1749 } 1750 1751 static HRESULT STDMETHODCALLTYPE debugsymbols_CreateSymbolGroup(IDebugSymbols3 *iface, IDebugSymbolGroup **group) 1752 { 1753 FIXME("%p, %p stub.\n", iface, group); 1754 1755 return E_NOTIMPL; 1756 } 1757 1758 static HRESULT STDMETHODCALLTYPE debugsymbols_StartSymbolMatch(IDebugSymbols3 *iface, const char *pattern, 1759 ULONG64 *handle) 1760 { 1761 FIXME("%p, %s, %p stub.\n", iface, pattern, handle); 1762 1763 return E_NOTIMPL; 1764 } 1765 1766 static HRESULT STDMETHODCALLTYPE debugsymbols_GetNextSymbolMatch(IDebugSymbols3 *iface, ULONG64 handle, char *buffer, 1767 ULONG buffer_size, ULONG *match_size, ULONG64 *offset) 1768 { 1769 FIXME("%p, %s, %p, %u, %p, %p stub.\n", iface, wine_dbgstr_longlong(handle), buffer, buffer_size, match_size, offset); 1770 1771 return E_NOTIMPL; 1772 } 1773 1774 static HRESULT STDMETHODCALLTYPE debugsymbols_EndSymbolMatch(IDebugSymbols3 *iface, ULONG64 handle) 1775 { 1776 FIXME("%p, %s stub.\n", iface, wine_dbgstr_longlong(handle)); 1777 1778 return E_NOTIMPL; 1779 } 1780 1781 static HRESULT STDMETHODCALLTYPE debugsymbols_Reload(IDebugSymbols3 *iface, const char *path) 1782 { 1783 FIXME("%p, %s stub.\n", iface, debugstr_a(path)); 1784 1785 return E_NOTIMPL; 1786 } 1787 1788 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolPath(IDebugSymbols3 *iface, char *buffer, ULONG buffer_size, 1789 ULONG *path_size) 1790 { 1791 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, path_size); 1792 1793 return E_NOTIMPL; 1794 } 1795 1796 static HRESULT STDMETHODCALLTYPE debugsymbols_SetSymbolPath(IDebugSymbols3 *iface, const char *path) 1797 { 1798 FIXME("%p, %s stub.\n", iface, debugstr_a(path)); 1799 1800 return E_NOTIMPL; 1801 } 1802 1803 static HRESULT STDMETHODCALLTYPE debugsymbols_AppendSymbolPath(IDebugSymbols3 *iface, const char *path) 1804 { 1805 FIXME("%p, %s stub.\n", iface, debugstr_a(path)); 1806 1807 return E_NOTIMPL; 1808 } 1809 1810 static HRESULT STDMETHODCALLTYPE debugsymbols_GetImagePath(IDebugSymbols3 *iface, char *buffer, ULONG buffer_size, 1811 ULONG *path_size) 1812 { 1813 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, path_size); 1814 1815 return E_NOTIMPL; 1816 } 1817 1818 static HRESULT STDMETHODCALLTYPE debugsymbols_SetImagePath(IDebugSymbols3 *iface, const char *path) 1819 { 1820 FIXME("%p, %s stub.\n", iface, debugstr_a(path)); 1821 1822 return E_NOTIMPL; 1823 } 1824 1825 static HRESULT STDMETHODCALLTYPE debugsymbols_AppendImagePath(IDebugSymbols3 *iface, const char *path) 1826 { 1827 FIXME("%p, %s stub.\n", iface, debugstr_a(path)); 1828 1829 return E_NOTIMPL; 1830 } 1831 1832 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourcePath(IDebugSymbols3 *iface, char *buffer, ULONG buffer_size, 1833 ULONG *path_size) 1834 { 1835 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, path_size); 1836 1837 return E_NOTIMPL; 1838 } 1839 1840 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourcePathElement(IDebugSymbols3 *iface, ULONG index, char *buffer, 1841 ULONG buffer_size, ULONG *element_size) 1842 { 1843 FIXME("%p, %u, %p, %u, %p stub.\n", iface, index, buffer, buffer_size, element_size); 1844 1845 return E_NOTIMPL; 1846 } 1847 1848 static HRESULT STDMETHODCALLTYPE debugsymbols_SetSourcePath(IDebugSymbols3 *iface, const char *path) 1849 { 1850 FIXME("%p, %s stub.\n", iface, debugstr_a(path)); 1851 1852 return E_NOTIMPL; 1853 } 1854 1855 static HRESULT STDMETHODCALLTYPE debugsymbols_AppendSourcePath(IDebugSymbols3 *iface, const char *path) 1856 { 1857 FIXME("%p, %s stub.\n", iface, debugstr_a(path)); 1858 1859 return E_NOTIMPL; 1860 } 1861 1862 static HRESULT STDMETHODCALLTYPE debugsymbols_FindSourceFile(IDebugSymbols3 *iface, ULONG start, const char *file, 1863 ULONG flags, ULONG *found_element, char *buffer, ULONG buffer_size, ULONG *found_size) 1864 { 1865 FIXME("%p, %u, %s, %#x, %p, %p, %u, %p stub.\n", iface, start, debugstr_a(file), flags, found_element, buffer, 1866 buffer_size, found_size); 1867 1868 return E_NOTIMPL; 1869 } 1870 1871 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourceFileLineOffsets(IDebugSymbols3 *iface, const char *file, 1872 ULONG64 *buffer, ULONG buffer_lines, ULONG *file_lines) 1873 { 1874 FIXME("%p, %s, %p, %u, %p stub.\n", iface, debugstr_a(file), buffer, buffer_lines, file_lines); 1875 1876 return E_NOTIMPL; 1877 } 1878 1879 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleVersionInformation(IDebugSymbols3 *iface, ULONG index, 1880 ULONG64 base, const char *item, void *buffer, ULONG buffer_size, ULONG *info_size) 1881 { 1882 struct debug_client *debug_client = impl_from_IDebugSymbols3(iface); 1883 const struct module_info *info; 1884 struct target_process *target; 1885 void *version_info, *ptr; 1886 HRESULT hr = E_FAIL; 1887 DWORD handle, size; 1888 1889 TRACE("%p, %u, %s, %s, %p, %u, %p.\n", iface, index, wine_dbgstr_longlong(base), debugstr_a(item), buffer, 1890 buffer_size, info_size); 1891 1892 if (!(target = debug_client_get_target(debug_client))) 1893 return E_UNEXPECTED; 1894 1895 if (index == DEBUG_ANY_ID) 1896 info = debug_target_get_module_info_by_base(target, base); 1897 else 1898 info = debug_target_get_module_info(target, index); 1899 1900 if (!info) 1901 { 1902 WARN("Was unable to locate module.\n"); 1903 return E_INVALIDARG; 1904 } 1905 1906 if (!(size = GetFileVersionInfoSizeA(info->image_name, &handle))) 1907 return E_FAIL; 1908 1909 if (!(version_info = heap_alloc(size))) 1910 return E_OUTOFMEMORY; 1911 1912 if (GetFileVersionInfoA(info->image_name, handle, size, version_info)) 1913 { 1914 #ifdef __REACTOS__ 1915 if (VerQueryValueA(version_info, item, &ptr, (PUINT) &size)) 1916 #else 1917 if (VerQueryValueA(version_info, item, &ptr, &size)) 1918 #endif 1919 { 1920 if (info_size) 1921 *info_size = size; 1922 1923 if (buffer && buffer_size) 1924 { 1925 unsigned int dst_len = min(size, buffer_size); 1926 if (dst_len) 1927 memcpy(buffer, ptr, dst_len); 1928 } 1929 1930 hr = buffer && buffer_size < size ? S_FALSE : S_OK; 1931 } 1932 } 1933 1934 heap_free(version_info); 1935 1936 return hr; 1937 } 1938 1939 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleNameString(IDebugSymbols3 *iface, ULONG which, ULONG index, 1940 ULONG64 base, char *buffer, ULONG buffer_size, ULONG *name_size) 1941 { 1942 struct debug_client *debug_client = impl_from_IDebugSymbols3(iface); 1943 const struct module_info *info; 1944 struct target_process *target; 1945 HRESULT hr; 1946 1947 TRACE("%p, %u, %u, %s, %p, %u, %p.\n", iface, which, index, wine_dbgstr_longlong(base), buffer, buffer_size, 1948 name_size); 1949 1950 if (!(target = debug_client_get_target(debug_client))) 1951 return E_UNEXPECTED; 1952 1953 if (index == DEBUG_ANY_ID) 1954 info = debug_target_get_module_info_by_base(target, base); 1955 else 1956 info = debug_target_get_module_info(target, index); 1957 1958 if (!info) 1959 { 1960 WARN("Was unable to locate module.\n"); 1961 return E_INVALIDARG; 1962 } 1963 1964 switch (which) 1965 { 1966 case DEBUG_MODNAME_IMAGE: 1967 #ifdef __REACTOS__ 1968 hr = debug_target_return_string(info->image_name, buffer, buffer_size, (UINT *) name_size); 1969 #else 1970 hr = debug_target_return_string(info->image_name, buffer, buffer_size, name_size); 1971 #endif 1972 break; 1973 case DEBUG_MODNAME_MODULE: 1974 case DEBUG_MODNAME_LOADED_IMAGE: 1975 case DEBUG_MODNAME_SYMBOL_FILE: 1976 case DEBUG_MODNAME_MAPPED_IMAGE: 1977 FIXME("Unsupported name info %d.\n", which); 1978 return E_NOTIMPL; 1979 default: 1980 WARN("Unknown name info %d.\n", which); 1981 return E_INVALIDARG; 1982 } 1983 1984 return hr; 1985 } 1986 1987 static HRESULT STDMETHODCALLTYPE debugsymbols_GetConstantName(IDebugSymbols3 *iface, ULONG64 module, ULONG type_id, 1988 ULONG64 value, char *buffer, ULONG buffer_size, ULONG *name_size) 1989 { 1990 FIXME("%p, %s, %u, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(module), type_id, 1991 wine_dbgstr_longlong(value), buffer, buffer_size, name_size); 1992 1993 return E_NOTIMPL; 1994 } 1995 1996 static HRESULT STDMETHODCALLTYPE debugsymbols_GetFieldName(IDebugSymbols3 *iface, ULONG64 module, ULONG type_id, 1997 ULONG field_index, char *buffer, ULONG buffer_size, ULONG *name_size) 1998 { 1999 FIXME("%p, %s, %u, %u, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(module), type_id, field_index, buffer, 2000 buffer_size, name_size); 2001 2002 return E_NOTIMPL; 2003 } 2004 2005 static HRESULT STDMETHODCALLTYPE debugsymbols_GetTypeOptions(IDebugSymbols3 *iface, ULONG *options) 2006 { 2007 FIXME("%p, %p stub.\n", iface, options); 2008 2009 return E_NOTIMPL; 2010 } 2011 2012 static HRESULT STDMETHODCALLTYPE debugsymbols_AddTypeOptions(IDebugSymbols3 *iface, ULONG options) 2013 { 2014 FIXME("%p, %#x stub.\n", iface, options); 2015 2016 return E_NOTIMPL; 2017 } 2018 2019 static HRESULT STDMETHODCALLTYPE debugsymbols_RemoveTypeOptions(IDebugSymbols3 *iface, ULONG options) 2020 { 2021 FIXME("%p, %#x stub.\n", iface, options); 2022 2023 return E_NOTIMPL; 2024 } 2025 2026 static HRESULT STDMETHODCALLTYPE debugsymbols_SetTypeOptions(IDebugSymbols3 *iface, ULONG options) 2027 { 2028 FIXME("%p, %#x stub.\n", iface, options); 2029 2030 return E_NOTIMPL; 2031 } 2032 2033 static HRESULT STDMETHODCALLTYPE debugsymbols_GetNameByOffsetWide(IDebugSymbols3 *iface, ULONG64 offset, WCHAR *buffer, 2034 ULONG buffer_size, ULONG *name_size, ULONG64 *displacement) 2035 { 2036 FIXME("%p, %s, %p, %u, %p, %p stub.\n", iface, wine_dbgstr_longlong(offset), buffer, buffer_size, name_size, 2037 displacement); 2038 2039 return E_NOTIMPL; 2040 } 2041 2042 static HRESULT STDMETHODCALLTYPE debugsymbols_GetOffsetByNameWide(IDebugSymbols3 *iface, const WCHAR *symbol, 2043 ULONG64 *offset) 2044 { 2045 FIXME("%p, %s, %p stub.\n", iface, debugstr_w(symbol), offset); 2046 2047 return E_NOTIMPL; 2048 } 2049 2050 static HRESULT STDMETHODCALLTYPE debugsymbols_GetNearNameByOffsetWide(IDebugSymbols3 *iface, ULONG64 offset, 2051 LONG delta, WCHAR *buffer, ULONG buffer_size, ULONG *name_size, ULONG64 *displacement) 2052 { 2053 FIXME("%p, %s, %d, %p, %u, %p, %p stub.\n", iface, wine_dbgstr_longlong(offset), delta, buffer, buffer_size, 2054 name_size, displacement); 2055 2056 return E_NOTIMPL; 2057 } 2058 2059 static HRESULT STDMETHODCALLTYPE debugsymbols_GetLineByOffsetWide(IDebugSymbols3 *iface, ULONG64 offset, ULONG *line, 2060 WCHAR *buffer, ULONG buffer_size, ULONG *file_size, ULONG64 *displacement) 2061 { 2062 FIXME("%p, %s, %p, %p, %u, %p, %p stub.\n", iface, wine_dbgstr_longlong(offset), line, buffer, buffer_size, 2063 file_size, displacement); 2064 2065 return E_NOTIMPL; 2066 } 2067 2068 static HRESULT STDMETHODCALLTYPE debugsymbols_GetOffsetByLineWide(IDebugSymbols3 *iface, ULONG line, const WCHAR *file, 2069 ULONG64 *offset) 2070 { 2071 FIXME("%p, %u, %s, %p stub.\n", iface, line, debugstr_w(file), offset); 2072 2073 return E_NOTIMPL; 2074 } 2075 2076 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleByModuleNameWide(IDebugSymbols3 *iface, const WCHAR *name, 2077 ULONG start_index, ULONG *index, ULONG64 *base) 2078 { 2079 FIXME("%p, %s, %u, %p, %p stub.\n", iface, debugstr_w(name), start_index, index, base); 2080 2081 return E_NOTIMPL; 2082 } 2083 2084 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolModuleWide(IDebugSymbols3 *iface, const WCHAR *symbol, 2085 ULONG64 *base) 2086 { 2087 FIXME("%p, %s, %p stub.\n", iface, debugstr_w(symbol), base); 2088 2089 return E_NOTIMPL; 2090 } 2091 2092 static HRESULT STDMETHODCALLTYPE debugsymbols_GetTypeNameWide(IDebugSymbols3 *iface, ULONG64 module, ULONG type_id, 2093 WCHAR *buffer, ULONG buffer_size, ULONG *name_size) 2094 { 2095 FIXME("%p, %s, %u, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(module), type_id, buffer, buffer_size, 2096 name_size); 2097 2098 return E_NOTIMPL; 2099 } 2100 2101 static HRESULT STDMETHODCALLTYPE debugsymbols_GetTypeIdWide(IDebugSymbols3 *iface, ULONG64 module, const WCHAR *name, 2102 ULONG *type_id) 2103 { 2104 FIXME("%p, %s, %s, %p stub.\n", iface, wine_dbgstr_longlong(module), debugstr_w(name), type_id); 2105 2106 return E_NOTIMPL; 2107 } 2108 2109 static HRESULT STDMETHODCALLTYPE debugsymbols_GetFieldOffsetWide(IDebugSymbols3 *iface, ULONG64 module, ULONG type_id, 2110 const WCHAR *field, ULONG *offset) 2111 { 2112 FIXME("%p, %s, %u, %s, %p stub.\n", iface, wine_dbgstr_longlong(module), type_id, debugstr_w(field), offset); 2113 2114 return E_NOTIMPL; 2115 } 2116 2117 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolTypeIdWide(IDebugSymbols3 *iface, const WCHAR *symbol, 2118 ULONG *type_id, ULONG64 *module) 2119 { 2120 FIXME("%p, %s, %p, %p stub.\n", iface, debugstr_w(symbol), type_id, module); 2121 2122 return E_NOTIMPL; 2123 } 2124 2125 static HRESULT STDMETHODCALLTYPE debugsymbols_GetScopeSymbolGroup2(IDebugSymbols3 *iface, ULONG flags, 2126 PDEBUG_SYMBOL_GROUP2 update, PDEBUG_SYMBOL_GROUP2 *symbols) 2127 { 2128 FIXME("%p, %#x, %p, %p stub.\n", iface, flags, update, symbols); 2129 2130 return E_NOTIMPL; 2131 } 2132 2133 static HRESULT STDMETHODCALLTYPE debugsymbols_CreateSymbolGroup2(IDebugSymbols3 *iface, PDEBUG_SYMBOL_GROUP2 *group) 2134 { 2135 FIXME("%p, %p stub.\n", iface, group); 2136 2137 return E_NOTIMPL; 2138 } 2139 2140 static HRESULT STDMETHODCALLTYPE debugsymbols_StartSymbolMatchWide(IDebugSymbols3 *iface, const WCHAR *pattern, 2141 ULONG64 *handle) 2142 { 2143 FIXME("%p, %s, %p stub.\n", iface, debugstr_w(pattern), handle); 2144 2145 return E_NOTIMPL; 2146 } 2147 2148 static HRESULT STDMETHODCALLTYPE debugsymbols_GetNextSymbolMatchWide(IDebugSymbols3 *iface, ULONG64 handle, 2149 WCHAR *buffer, ULONG buffer_size, ULONG *match_size, ULONG64 *offset) 2150 { 2151 FIXME("%p, %s, %p, %u, %p, %p stub.\n", iface, wine_dbgstr_longlong(handle), buffer, buffer_size, match_size, offset); 2152 2153 return E_NOTIMPL; 2154 } 2155 2156 static HRESULT STDMETHODCALLTYPE debugsymbols_ReloadWide(IDebugSymbols3 *iface, const WCHAR *module) 2157 { 2158 FIXME("%p, %s stub.\n", iface, debugstr_w(module)); 2159 2160 return E_NOTIMPL; 2161 } 2162 2163 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolPathWide(IDebugSymbols3 *iface, WCHAR *buffer, ULONG buffer_size, 2164 ULONG *path_size) 2165 { 2166 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, path_size); 2167 2168 return E_NOTIMPL; 2169 } 2170 2171 static HRESULT STDMETHODCALLTYPE debugsymbols_SetSymbolPathWide(IDebugSymbols3 *iface, const WCHAR *path) 2172 { 2173 FIXME("%p, %s stub.\n", iface, debugstr_w(path)); 2174 2175 return E_NOTIMPL; 2176 } 2177 2178 static HRESULT STDMETHODCALLTYPE debugsymbols_AppendSymbolPathWide(IDebugSymbols3 *iface, const WCHAR *addition) 2179 { 2180 FIXME("%p, %s stub.\n", iface, debugstr_w(addition)); 2181 2182 return E_NOTIMPL; 2183 } 2184 2185 static HRESULT STDMETHODCALLTYPE debugsymbols_GetImagePathWide(IDebugSymbols3 *iface, WCHAR *buffer, ULONG buffer_size, 2186 ULONG *path_size) 2187 { 2188 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, path_size); 2189 2190 return E_NOTIMPL; 2191 } 2192 2193 static HRESULT STDMETHODCALLTYPE debugsymbols_SetImagePathWide(IDebugSymbols3 *iface, const WCHAR *path) 2194 { 2195 FIXME("%p, %s stub.\n", iface, debugstr_w(path)); 2196 2197 return E_NOTIMPL; 2198 } 2199 2200 static HRESULT STDMETHODCALLTYPE debugsymbols_AppendImagePathWide(IDebugSymbols3 *iface, const WCHAR *addition) 2201 { 2202 FIXME("%p, %s stub.\n", iface, debugstr_w(addition)); 2203 2204 return E_NOTIMPL; 2205 } 2206 2207 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourcePathWide(IDebugSymbols3 *iface, WCHAR *buffer, ULONG buffer_size, 2208 ULONG *path_size) 2209 { 2210 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, path_size); 2211 2212 return E_NOTIMPL; 2213 } 2214 2215 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourcePathElementWide(IDebugSymbols3 *iface, ULONG index, 2216 WCHAR *buffer, ULONG buffer_size, ULONG *element_size) 2217 { 2218 FIXME("%p, %u, %p, %u, %p stub.\n", iface, index, buffer, buffer_size, element_size); 2219 2220 return E_NOTIMPL; 2221 } 2222 2223 static HRESULT STDMETHODCALLTYPE debugsymbols_SetSourcePathWide(IDebugSymbols3 *iface, const WCHAR *path) 2224 { 2225 FIXME("%p, %s stub.\n", iface, debugstr_w(path)); 2226 2227 return E_NOTIMPL; 2228 } 2229 2230 static HRESULT STDMETHODCALLTYPE debugsymbols_AppendSourcePathWide(IDebugSymbols3 *iface, const WCHAR *addition) 2231 { 2232 FIXME("%p, %s stub.\n", iface, debugstr_w(addition)); 2233 2234 return E_NOTIMPL; 2235 } 2236 2237 static HRESULT STDMETHODCALLTYPE debugsymbols_FindSourceFileWide(IDebugSymbols3 *iface, ULONG start_element, 2238 const WCHAR *file, ULONG flags, ULONG *found_element, WCHAR *buffer, ULONG buffer_size, ULONG *found_size) 2239 { 2240 FIXME("%p, %u, %s, %#x, %p, %p, %u, %p stub.\n", iface, start_element, debugstr_w(file), flags, found_element, 2241 buffer, buffer_size, found_size); 2242 2243 return E_NOTIMPL; 2244 } 2245 2246 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourceFileLineOffsetsWide(IDebugSymbols3 *iface, const WCHAR *file, 2247 ULONG64 *buffer, ULONG buffer_lines, ULONG *file_lines) 2248 { 2249 FIXME("%p, %s, %p, %u, %p stub.\n", iface, debugstr_w(file), buffer, buffer_lines, file_lines); 2250 2251 return E_NOTIMPL; 2252 } 2253 2254 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleVersionInformationWide(IDebugSymbols3 *iface, ULONG index, 2255 ULONG64 base, const WCHAR *item, void *buffer, ULONG buffer_size, ULONG *version_info_size) 2256 { 2257 FIXME("%p, %u, %s, %s, %p, %u, %p stub.\n", iface, index, wine_dbgstr_longlong(base), debugstr_w(item), buffer, 2258 buffer_size, version_info_size); 2259 2260 return E_NOTIMPL; 2261 } 2262 2263 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleNameStringWide(IDebugSymbols3 *iface, ULONG which, ULONG index, 2264 ULONG64 base, WCHAR *buffer, ULONG buffer_size, ULONG *name_size) 2265 { 2266 FIXME("%p, %u, %u, %s, %p, %u, %p stub.\n", iface, which, index, wine_dbgstr_longlong(base), buffer, buffer_size, 2267 name_size); 2268 2269 return E_NOTIMPL; 2270 } 2271 2272 static HRESULT STDMETHODCALLTYPE debugsymbols_GetConstantNameWide(IDebugSymbols3 *iface, ULONG64 module, ULONG type_id, 2273 ULONG64 value, WCHAR *buffer, ULONG buffer_size, ULONG *name_size) 2274 { 2275 FIXME("%p, %s, %u, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(module), type_id, 2276 wine_dbgstr_longlong(value), buffer, buffer_size, name_size); 2277 2278 return E_NOTIMPL; 2279 } 2280 2281 static HRESULT STDMETHODCALLTYPE debugsymbols_GetFieldNameWide(IDebugSymbols3 *iface, ULONG64 module, ULONG type_id, 2282 ULONG field_index, WCHAR *buffer, ULONG buffer_size, ULONG *name_size) 2283 { 2284 FIXME("%p, %s, %u, %u, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(module), type_id, field_index, buffer, 2285 buffer_size, name_size); 2286 2287 return E_NOTIMPL; 2288 } 2289 2290 static HRESULT STDMETHODCALLTYPE debugsymbols_IsManagedModule(IDebugSymbols3 *iface, ULONG index, ULONG64 base) 2291 { 2292 FIXME("%p, %u, %s stub.\n", iface, index, wine_dbgstr_longlong(base)); 2293 2294 return E_NOTIMPL; 2295 } 2296 2297 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleByModuleName2(IDebugSymbols3 *iface, const char *name, 2298 ULONG start_index, ULONG flags, ULONG *index, ULONG64 *base) 2299 { 2300 FIXME("%p, %s, %u, %#x, %p, %p stub.\n", iface, debugstr_a(name), start_index, flags, index, base); 2301 2302 return E_NOTIMPL; 2303 } 2304 2305 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleByModuleName2Wide(IDebugSymbols3 *iface, const WCHAR *name, 2306 ULONG start_index, ULONG flags, ULONG *index, ULONG64 *base) 2307 { 2308 FIXME("%p, %s, %u, %#x, %p, %p stub.\n", iface, debugstr_w(name), start_index, flags, index, base); 2309 2310 return E_NOTIMPL; 2311 } 2312 2313 static HRESULT STDMETHODCALLTYPE debugsymbols_GetModuleByOffset2(IDebugSymbols3 *iface, ULONG64 offset, 2314 ULONG start_index, ULONG flags, ULONG *index, ULONG64 *base) 2315 { 2316 FIXME("%p, %s, %u, %#x, %p, %p stub.\n", iface, wine_dbgstr_longlong(offset), start_index, flags, index, base); 2317 2318 return E_NOTIMPL; 2319 } 2320 2321 static HRESULT STDMETHODCALLTYPE debugsymbols_AddSyntheticModule(IDebugSymbols3 *iface, ULONG64 base, ULONG size, 2322 const char *image_path, const char *module_name, ULONG flags) 2323 { 2324 FIXME("%p, %s, %u, %s, %s, %#x stub.\n", iface, wine_dbgstr_longlong(base), size, debugstr_a(image_path), 2325 debugstr_a(module_name), flags); 2326 2327 return E_NOTIMPL; 2328 } 2329 2330 static HRESULT STDMETHODCALLTYPE debugsymbols_AddSyntheticModuleWide(IDebugSymbols3 *iface, ULONG64 base, ULONG size, 2331 const WCHAR *image_path, const WCHAR *module_name, ULONG flags) 2332 { 2333 FIXME("%p, %s, %u, %s, %s, %#x stub.\n", iface, wine_dbgstr_longlong(base), size, debugstr_w(image_path), 2334 debugstr_w(module_name), flags); 2335 2336 return E_NOTIMPL; 2337 } 2338 2339 static HRESULT STDMETHODCALLTYPE debugsymbols_RemoveSyntheticModule(IDebugSymbols3 *iface, ULONG64 base) 2340 { 2341 FIXME("%p, %s stub.\n", iface, wine_dbgstr_longlong(base)); 2342 2343 return E_NOTIMPL; 2344 } 2345 2346 static HRESULT STDMETHODCALLTYPE debugsymbols_GetCurrentScopeFrameIndex(IDebugSymbols3 *iface, ULONG *index) 2347 { 2348 FIXME("%p, %p stub.\n", iface, index); 2349 2350 return E_NOTIMPL; 2351 } 2352 2353 static HRESULT STDMETHODCALLTYPE debugsymbols_SetScopeFrameByIndex(IDebugSymbols3 *iface, ULONG index) 2354 { 2355 FIXME("%p, %u stub.\n", iface, index); 2356 2357 return E_NOTIMPL; 2358 } 2359 2360 static HRESULT STDMETHODCALLTYPE debugsymbols_SetScopeFromJitDebugInfo(IDebugSymbols3 *iface, ULONG output_control, 2361 ULONG64 info_offset) 2362 { 2363 FIXME("%p, %u, %s stub.\n", iface, output_control, wine_dbgstr_longlong(info_offset)); 2364 2365 return E_NOTIMPL; 2366 } 2367 2368 static HRESULT STDMETHODCALLTYPE debugsymbols_SetScopeFromStoredEvent(IDebugSymbols3 *iface) 2369 { 2370 FIXME("%p stub.\n", iface); 2371 2372 return E_NOTIMPL; 2373 } 2374 2375 static HRESULT STDMETHODCALLTYPE debugsymbols_OutputSymbolByOffset(IDebugSymbols3 *iface, ULONG output_control, 2376 ULONG flags, ULONG64 offset) 2377 { 2378 FIXME("%p, %u, %#x, %s stub.\n", iface, output_control, flags, wine_dbgstr_longlong(offset)); 2379 2380 return E_NOTIMPL; 2381 } 2382 2383 static HRESULT STDMETHODCALLTYPE debugsymbols_GetFunctionEntryByOffset(IDebugSymbols3 *iface, ULONG64 offset, 2384 ULONG flags, void *buffer, ULONG buffer_size, ULONG *needed_size) 2385 { 2386 FIXME("%p, %s, %#x, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), flags, buffer, buffer_size, 2387 needed_size); 2388 2389 return E_NOTIMPL; 2390 } 2391 2392 static HRESULT STDMETHODCALLTYPE debugsymbols_GetFieldTypeAndOffset(IDebugSymbols3 *iface, ULONG64 module, 2393 ULONG container_type_id, const char *field, ULONG *field_type_id, ULONG *offset) 2394 { 2395 FIXME("%p, %s, %u, %s, %p, %p stub.\n", iface, wine_dbgstr_longlong(module), container_type_id, debugstr_a(field), 2396 field_type_id, offset); 2397 2398 return E_NOTIMPL; 2399 } 2400 2401 static HRESULT STDMETHODCALLTYPE debugsymbols_GetFieldTypeAndOffsetWide(IDebugSymbols3 *iface, ULONG64 module, 2402 ULONG container_type_id, const WCHAR *field, ULONG *field_type_id, ULONG *offset) 2403 { 2404 FIXME("%p, %s, %u, %s, %p, %p stub.\n", iface, wine_dbgstr_longlong(module), container_type_id, debugstr_w(field), 2405 field_type_id, offset); 2406 2407 return E_NOTIMPL; 2408 } 2409 2410 static HRESULT STDMETHODCALLTYPE debugsymbols_AddSyntheticSymbol(IDebugSymbols3 *iface, ULONG64 offset, ULONG size, 2411 const char *name, ULONG flags, DEBUG_MODULE_AND_ID *id) 2412 { 2413 FIXME("%p, %s, %u, %s, %#x, %p stub.\n", iface, wine_dbgstr_longlong(offset), size, debugstr_a(name), flags, id); 2414 2415 return E_NOTIMPL; 2416 } 2417 2418 static HRESULT STDMETHODCALLTYPE debugsymbols_AddSyntheticSymbolWide(IDebugSymbols3 *iface, ULONG64 offset, ULONG size, 2419 const WCHAR *name, ULONG flags, DEBUG_MODULE_AND_ID *id) 2420 { 2421 FIXME("%p, %s, %u, %s, %#x, %p stub.\n", iface, wine_dbgstr_longlong(offset), size, debugstr_w(name), flags, id); 2422 2423 return E_NOTIMPL; 2424 } 2425 2426 static HRESULT STDMETHODCALLTYPE debugsymbols_RemoveSyntheticSymbol(IDebugSymbols3 *iface, DEBUG_MODULE_AND_ID *id) 2427 { 2428 FIXME("%p, %p stub.\n", iface, id); 2429 2430 return E_NOTIMPL; 2431 } 2432 2433 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolEntriesByOffset(IDebugSymbols3 *iface, ULONG64 offset, 2434 ULONG flags, DEBUG_MODULE_AND_ID *ids, LONG64 *displacements, ULONG count, ULONG *entries) 2435 { 2436 FIXME("%p, %s, %#x, %p, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), flags, ids, displacements, count, 2437 entries); 2438 2439 return E_NOTIMPL; 2440 } 2441 2442 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolEntriesByName(IDebugSymbols3 *iface, const char *symbol, 2443 ULONG flags, DEBUG_MODULE_AND_ID *ids, ULONG count, ULONG *entries) 2444 { 2445 FIXME("%p, %s, %#x, %p, %u, %p stub.\n", iface, debugstr_a(symbol), flags, ids, count, entries); 2446 2447 return E_NOTIMPL; 2448 } 2449 2450 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolEntriesByNameWide(IDebugSymbols3 *iface, const WCHAR *symbol, 2451 ULONG flags, DEBUG_MODULE_AND_ID *ids, ULONG count, ULONG *entries) 2452 { 2453 FIXME("%p, %s, %#x, %p, %u, %p stub.\n", iface, debugstr_w(symbol), flags, ids, count, entries); 2454 2455 return E_NOTIMPL; 2456 } 2457 2458 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolEntryByToken(IDebugSymbols3 *iface, ULONG64 base, ULONG token, 2459 DEBUG_MODULE_AND_ID *id) 2460 { 2461 FIXME("%p, %s, %p stub.\n", iface, wine_dbgstr_longlong(base), id); 2462 2463 return E_NOTIMPL; 2464 } 2465 2466 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolEntryInformation(IDebugSymbols3 *iface, DEBUG_MODULE_AND_ID *id, 2467 DEBUG_SYMBOL_ENTRY *info) 2468 { 2469 FIXME("%p, %p, %p stub.\n", iface, id, info); 2470 2471 return E_NOTIMPL; 2472 } 2473 2474 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolEntryString(IDebugSymbols3 *iface, DEBUG_MODULE_AND_ID *id, 2475 ULONG which, char *buffer, ULONG buffer_size, ULONG *string_size) 2476 { 2477 FIXME("%p, %p, %u, %p, %u, %p stub.\n", iface, id, which, buffer, buffer_size, string_size); 2478 2479 return E_NOTIMPL; 2480 } 2481 2482 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolEntryStringWide(IDebugSymbols3 *iface, DEBUG_MODULE_AND_ID *id, 2483 ULONG which, WCHAR *buffer, ULONG buffer_size, ULONG *string_size) 2484 { 2485 FIXME("%p, %p, %u, %p, %u, %p stub.\n", iface, id, which, buffer, buffer_size, string_size); 2486 2487 return E_NOTIMPL; 2488 } 2489 2490 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolEntryOffsetRegions(IDebugSymbols3 *iface, DEBUG_MODULE_AND_ID *id, 2491 ULONG flags, DEBUG_OFFSET_REGION *regions, ULONG regions_count, ULONG *regions_avail) 2492 { 2493 FIXME("%p, %p, %#x, %p, %u, %p stub.\n", iface, id, flags, regions, regions_count, regions_avail); 2494 2495 return E_NOTIMPL; 2496 } 2497 2498 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSymbolEntryBySymbolEntry(IDebugSymbols3 *iface, 2499 DEBUG_MODULE_AND_ID *from_id, ULONG flags, DEBUG_MODULE_AND_ID *to_id) 2500 { 2501 FIXME("%p, %p, %#x, %p stub.\n", iface, from_id, flags, to_id); 2502 2503 return E_NOTIMPL; 2504 } 2505 2506 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourceEntriesByOffset(IDebugSymbols3 *iface, ULONG64 offset, 2507 ULONG flags, DEBUG_SYMBOL_SOURCE_ENTRY *entries, ULONG count, ULONG *entries_avail) 2508 { 2509 FIXME("%p, %s, %#x, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(offset), flags, entries, count, entries_avail); 2510 2511 return E_NOTIMPL; 2512 } 2513 2514 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourceEntriesByLine(IDebugSymbols3 *iface, ULONG line, 2515 const char *file, ULONG flags, DEBUG_SYMBOL_SOURCE_ENTRY *entries, ULONG count, ULONG *entries_avail) 2516 { 2517 FIXME("%p, %s, %#x, %p, %u, %p stub.\n", iface, debugstr_a(file), flags, entries, count, entries_avail); 2518 2519 return E_NOTIMPL; 2520 } 2521 2522 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourceEntriesByLineWide(IDebugSymbols3 *iface, ULONG line, 2523 const WCHAR *file, ULONG flags, DEBUG_SYMBOL_SOURCE_ENTRY *entries, ULONG count, ULONG *entries_avail) 2524 { 2525 FIXME("%p, %s, %#x, %p, %u, %p stub.\n", iface, debugstr_w(file), flags, entries, count, entries_avail); 2526 2527 return E_NOTIMPL; 2528 } 2529 2530 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourceEntryString(IDebugSymbols3 *iface, 2531 DEBUG_SYMBOL_SOURCE_ENTRY *entry, ULONG which, char *buffer, ULONG buffer_size, ULONG *string_size) 2532 { 2533 FIXME("%p, %p, %u, %p, %u, %p stub.\n", iface, entry, which, buffer, buffer_size, string_size); 2534 2535 return E_NOTIMPL; 2536 } 2537 2538 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourceEntryStringWide(IDebugSymbols3 *iface, 2539 DEBUG_SYMBOL_SOURCE_ENTRY *entry, ULONG which, WCHAR *buffer, ULONG buffer_size, ULONG *string_size) 2540 { 2541 FIXME("%p, %p, %u, %p, %u, %p stub.\n", iface, entry, which, buffer, buffer_size, string_size); 2542 2543 return E_NOTIMPL; 2544 } 2545 2546 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourceEntryOffsetRegions(IDebugSymbols3 *iface, 2547 DEBUG_SYMBOL_SOURCE_ENTRY *entry, ULONG flags, DEBUG_OFFSET_REGION *regions, ULONG count, ULONG *regions_avail) 2548 { 2549 FIXME("%p, %p, %#x, %p, %u, %p stub.\n", iface, entry, flags, regions, count, regions_avail); 2550 2551 return E_NOTIMPL; 2552 } 2553 2554 static HRESULT STDMETHODCALLTYPE debugsymbols_GetSourceEntryBySourceEntry(IDebugSymbols3 *iface, 2555 DEBUG_SYMBOL_SOURCE_ENTRY *from_entry, ULONG flags, DEBUG_SYMBOL_SOURCE_ENTRY *to_entry) 2556 { 2557 FIXME("%p, %p, %#x, %p stub.\n", iface, from_entry, flags, to_entry); 2558 2559 return E_NOTIMPL; 2560 } 2561 2562 static const IDebugSymbols3Vtbl debugsymbolsvtbl = 2563 { 2564 debugsymbols_QueryInterface, 2565 debugsymbols_AddRef, 2566 debugsymbols_Release, 2567 debugsymbols_GetSymbolOptions, 2568 debugsymbols_AddSymbolOptions, 2569 debugsymbols_RemoveSymbolOptions, 2570 debugsymbols_SetSymbolOptions, 2571 debugsymbols_GetNameByOffset, 2572 debugsymbols_GetOffsetByName, 2573 debugsymbols_GetNearNameByOffset, 2574 debugsymbols_GetLineByOffset, 2575 debugsymbols_GetOffsetByLine, 2576 debugsymbols_GetNumberModules, 2577 debugsymbols_GetModuleByIndex, 2578 debugsymbols_GetModuleByModuleName, 2579 debugsymbols_GetModuleByOffset, 2580 debugsymbols_GetModuleNames, 2581 debugsymbols_GetModuleParameters, 2582 debugsymbols_GetSymbolModule, 2583 debugsymbols_GetTypeName, 2584 debugsymbols_GetTypeId, 2585 debugsymbols_GetTypeSize, 2586 debugsymbols_GetFieldOffset, 2587 debugsymbols_GetSymbolTypeId, 2588 debugsymbols_GetOffsetTypeId, 2589 debugsymbols_ReadTypedDataVirtual, 2590 debugsymbols_WriteTypedDataVirtual, 2591 debugsymbols_OutputTypedDataVirtual, 2592 debugsymbols_ReadTypedDataPhysical, 2593 debugsymbols_WriteTypedDataPhysical, 2594 debugsymbols_OutputTypedDataPhysical, 2595 debugsymbols_GetScope, 2596 debugsymbols_SetScope, 2597 debugsymbols_ResetScope, 2598 debugsymbols_GetScopeSymbolGroup, 2599 debugsymbols_CreateSymbolGroup, 2600 debugsymbols_StartSymbolMatch, 2601 debugsymbols_GetNextSymbolMatch, 2602 debugsymbols_EndSymbolMatch, 2603 debugsymbols_Reload, 2604 debugsymbols_GetSymbolPath, 2605 debugsymbols_SetSymbolPath, 2606 debugsymbols_AppendSymbolPath, 2607 debugsymbols_GetImagePath, 2608 debugsymbols_SetImagePath, 2609 debugsymbols_AppendImagePath, 2610 debugsymbols_GetSourcePath, 2611 debugsymbols_GetSourcePathElement, 2612 debugsymbols_SetSourcePath, 2613 debugsymbols_AppendSourcePath, 2614 debugsymbols_FindSourceFile, 2615 debugsymbols_GetSourceFileLineOffsets, 2616 /* IDebugSymbols2 */ 2617 debugsymbols_GetModuleVersionInformation, 2618 debugsymbols_GetModuleNameString, 2619 debugsymbols_GetConstantName, 2620 debugsymbols_GetFieldName, 2621 debugsymbols_GetTypeOptions, 2622 debugsymbols_AddTypeOptions, 2623 debugsymbols_RemoveTypeOptions, 2624 debugsymbols_SetTypeOptions, 2625 /* IDebugSymbols3 */ 2626 debugsymbols_GetNameByOffsetWide, 2627 debugsymbols_GetOffsetByNameWide, 2628 debugsymbols_GetNearNameByOffsetWide, 2629 debugsymbols_GetLineByOffsetWide, 2630 debugsymbols_GetOffsetByLineWide, 2631 debugsymbols_GetModuleByModuleNameWide, 2632 debugsymbols_GetSymbolModuleWide, 2633 debugsymbols_GetTypeNameWide, 2634 debugsymbols_GetTypeIdWide, 2635 debugsymbols_GetFieldOffsetWide, 2636 debugsymbols_GetSymbolTypeIdWide, 2637 debugsymbols_GetScopeSymbolGroup2, 2638 debugsymbols_CreateSymbolGroup2, 2639 debugsymbols_StartSymbolMatchWide, 2640 debugsymbols_GetNextSymbolMatchWide, 2641 debugsymbols_ReloadWide, 2642 debugsymbols_GetSymbolPathWide, 2643 debugsymbols_SetSymbolPathWide, 2644 debugsymbols_AppendSymbolPathWide, 2645 debugsymbols_GetImagePathWide, 2646 debugsymbols_SetImagePathWide, 2647 debugsymbols_AppendImagePathWide, 2648 debugsymbols_GetSourcePathWide, 2649 debugsymbols_GetSourcePathElementWide, 2650 debugsymbols_SetSourcePathWide, 2651 debugsymbols_AppendSourcePathWide, 2652 debugsymbols_FindSourceFileWide, 2653 debugsymbols_GetSourceFileLineOffsetsWide, 2654 debugsymbols_GetModuleVersionInformationWide, 2655 debugsymbols_GetModuleNameStringWide, 2656 debugsymbols_GetConstantNameWide, 2657 debugsymbols_GetFieldNameWide, 2658 debugsymbols_IsManagedModule, 2659 debugsymbols_GetModuleByModuleName2, 2660 debugsymbols_GetModuleByModuleName2Wide, 2661 debugsymbols_GetModuleByOffset2, 2662 debugsymbols_AddSyntheticModule, 2663 debugsymbols_AddSyntheticModuleWide, 2664 debugsymbols_RemoveSyntheticModule, 2665 debugsymbols_GetCurrentScopeFrameIndex, 2666 debugsymbols_SetScopeFrameByIndex, 2667 debugsymbols_SetScopeFromJitDebugInfo, 2668 debugsymbols_SetScopeFromStoredEvent, 2669 debugsymbols_OutputSymbolByOffset, 2670 debugsymbols_GetFunctionEntryByOffset, 2671 debugsymbols_GetFieldTypeAndOffset, 2672 debugsymbols_GetFieldTypeAndOffsetWide, 2673 debugsymbols_AddSyntheticSymbol, 2674 debugsymbols_AddSyntheticSymbolWide, 2675 debugsymbols_RemoveSyntheticSymbol, 2676 debugsymbols_GetSymbolEntriesByOffset, 2677 debugsymbols_GetSymbolEntriesByName, 2678 debugsymbols_GetSymbolEntriesByNameWide, 2679 debugsymbols_GetSymbolEntryByToken, 2680 debugsymbols_GetSymbolEntryInformation, 2681 debugsymbols_GetSymbolEntryString, 2682 debugsymbols_GetSymbolEntryStringWide, 2683 debugsymbols_GetSymbolEntryOffsetRegions, 2684 debugsymbols_GetSymbolEntryBySymbolEntry, 2685 debugsymbols_GetSourceEntriesByOffset, 2686 debugsymbols_GetSourceEntriesByLine, 2687 debugsymbols_GetSourceEntriesByLineWide, 2688 debugsymbols_GetSourceEntryString, 2689 debugsymbols_GetSourceEntryStringWide, 2690 debugsymbols_GetSourceEntryOffsetRegions, 2691 debugsymbols_GetSourceEntryBySourceEntry, 2692 }; 2693 2694 static HRESULT STDMETHODCALLTYPE debugcontrol_QueryInterface(IDebugControl2 *iface, REFIID riid, void **obj) 2695 { 2696 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 2697 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 2698 return IUnknown_QueryInterface(unk, riid, obj); 2699 } 2700 2701 static ULONG STDMETHODCALLTYPE debugcontrol_AddRef(IDebugControl2 *iface) 2702 { 2703 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 2704 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 2705 return IUnknown_AddRef(unk); 2706 } 2707 2708 static ULONG STDMETHODCALLTYPE debugcontrol_Release(IDebugControl2 *iface) 2709 { 2710 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 2711 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 2712 return IUnknown_Release(unk); 2713 } 2714 2715 static HRESULT STDMETHODCALLTYPE debugcontrol_GetInterrupt(IDebugControl2 *iface) 2716 { 2717 FIXME("%p stub.\n", iface); 2718 2719 return E_NOTIMPL; 2720 } 2721 2722 static HRESULT STDMETHODCALLTYPE debugcontrol_SetInterrupt(IDebugControl2 *iface, ULONG flags) 2723 { 2724 FIXME("%p, %#x stub.\n", iface, flags); 2725 2726 return E_NOTIMPL; 2727 } 2728 2729 static HRESULT STDMETHODCALLTYPE debugcontrol_GetInterruptTimeout(IDebugControl2 *iface, ULONG *timeout) 2730 { 2731 FIXME("%p, %p stub.\n", iface, timeout); 2732 2733 return E_NOTIMPL; 2734 } 2735 2736 static HRESULT STDMETHODCALLTYPE debugcontrol_SetInterruptTimeout(IDebugControl2 *iface, ULONG timeout) 2737 { 2738 FIXME("%p, %u stub.\n", iface, timeout); 2739 2740 return E_NOTIMPL; 2741 } 2742 2743 static HRESULT STDMETHODCALLTYPE debugcontrol_GetLogFile(IDebugControl2 *iface, char *buffer, ULONG buffer_size, 2744 ULONG *file_size, BOOL *append) 2745 { 2746 FIXME("%p, %p, %u, %p, %p stub.\n", iface, buffer, buffer_size, file_size, append); 2747 2748 return E_NOTIMPL; 2749 } 2750 2751 static HRESULT STDMETHODCALLTYPE debugcontrol_OpenLogFile(IDebugControl2 *iface, const char *file, BOOL append) 2752 { 2753 FIXME("%p, %s, %d stub.\n", iface, debugstr_a(file), append); 2754 2755 return E_NOTIMPL; 2756 } 2757 static HRESULT STDMETHODCALLTYPE debugcontrol_CloseLogFile(IDebugControl2 *iface) 2758 { 2759 FIXME("%p stub.\n", iface); 2760 2761 return E_NOTIMPL; 2762 } 2763 static HRESULT STDMETHODCALLTYPE debugcontrol_GetLogMask(IDebugControl2 *iface, ULONG *mask) 2764 { 2765 FIXME("%p, %p stub.\n", iface, mask); 2766 2767 return E_NOTIMPL; 2768 } 2769 2770 static HRESULT STDMETHODCALLTYPE debugcontrol_SetLogMask(IDebugControl2 *iface, ULONG mask) 2771 { 2772 FIXME("%p, %#x stub.\n", iface, mask); 2773 2774 return E_NOTIMPL; 2775 } 2776 2777 static HRESULT STDMETHODCALLTYPE debugcontrol_Input(IDebugControl2 *iface, char *buffer, ULONG buffer_size, 2778 ULONG *input_size) 2779 { 2780 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, input_size); 2781 2782 return E_NOTIMPL; 2783 } 2784 2785 static HRESULT STDMETHODCALLTYPE debugcontrol_ReturnInput(IDebugControl2 *iface, const char *buffer) 2786 { 2787 FIXME("%p, %s stub.\n", iface, debugstr_a(buffer)); 2788 2789 return E_NOTIMPL; 2790 } 2791 2792 static HRESULT STDMETHODVCALLTYPE debugcontrol_Output(IDebugControl2 *iface, ULONG mask, const char *format, ...) 2793 { 2794 FIXME("%p, %#x, %s stub.\n", iface, mask, debugstr_a(format)); 2795 2796 return E_NOTIMPL; 2797 } 2798 2799 static HRESULT STDMETHODCALLTYPE debugcontrol_OutputVaList(IDebugControl2 *iface, ULONG mask, const char *format, 2800 __ms_va_list args) 2801 { 2802 FIXME("%p, %#x, %s stub.\n", iface, mask, debugstr_a(format)); 2803 2804 return E_NOTIMPL; 2805 } 2806 2807 static HRESULT STDMETHODVCALLTYPE debugcontrol_ControlledOutput(IDebugControl2 *iface, ULONG output_control, 2808 ULONG mask, const char *format, ...) 2809 { 2810 FIXME("%p, %u, %#x, %s stub.\n", iface, output_control, mask, debugstr_a(format)); 2811 2812 return E_NOTIMPL; 2813 } 2814 2815 static HRESULT STDMETHODCALLTYPE debugcontrol_ControlledOutputVaList(IDebugControl2 *iface, ULONG output_control, 2816 ULONG mask, const char *format, __ms_va_list args) 2817 { 2818 FIXME("%p, %u, %#x, %s stub.\n", iface, output_control, mask, debugstr_a(format)); 2819 2820 return E_NOTIMPL; 2821 } 2822 2823 static HRESULT STDMETHODVCALLTYPE debugcontrol_OutputPrompt(IDebugControl2 *iface, ULONG output_control, 2824 const char *format, ...) 2825 { 2826 FIXME("%p, %u, %s stub.\n", iface, output_control, debugstr_a(format)); 2827 2828 return E_NOTIMPL; 2829 } 2830 2831 static HRESULT STDMETHODCALLTYPE debugcontrol_OutputPromptVaList(IDebugControl2 *iface, ULONG output_control, 2832 const char *format, __ms_va_list args) 2833 { 2834 FIXME("%p, %u, %s stub.\n", iface, output_control, debugstr_a(format)); 2835 2836 return E_NOTIMPL; 2837 } 2838 2839 static HRESULT STDMETHODCALLTYPE debugcontrol_GetPromptText(IDebugControl2 *iface, char *buffer, ULONG buffer_size, 2840 ULONG *text_size) 2841 { 2842 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, text_size); 2843 2844 return E_NOTIMPL; 2845 } 2846 2847 static HRESULT STDMETHODCALLTYPE debugcontrol_OutputCurrentState(IDebugControl2 *iface, ULONG output_control, 2848 ULONG flags) 2849 { 2850 FIXME("%p, %u, %#x stub.\n", iface, output_control, flags); 2851 2852 return E_NOTIMPL; 2853 } 2854 2855 static HRESULT STDMETHODCALLTYPE debugcontrol_OutputVersionInformation(IDebugControl2 *iface, ULONG output_control) 2856 { 2857 FIXME("%p, %u stub.\n", iface, output_control); 2858 2859 return E_NOTIMPL; 2860 } 2861 2862 static HRESULT STDMETHODCALLTYPE debugcontrol_GetNotifyEventHandle(IDebugControl2 *iface, ULONG64 *handle) 2863 { 2864 FIXME("%p, %p stub.\n", iface, handle); 2865 2866 return E_NOTIMPL; 2867 } 2868 2869 static HRESULT STDMETHODCALLTYPE debugcontrol_SetNotifyEventHandle(IDebugControl2 *iface, ULONG64 handle) 2870 { 2871 FIXME("%p, %s stub.\n", iface, wine_dbgstr_longlong(handle)); 2872 2873 return E_NOTIMPL; 2874 } 2875 2876 static HRESULT STDMETHODCALLTYPE debugcontrol_Assemble(IDebugControl2 *iface, ULONG64 offset, const char *code, 2877 ULONG64 *end_offset) 2878 { 2879 FIXME("%p, %s, %s, %p stub.\n", iface, wine_dbgstr_longlong(offset), debugstr_a(code), end_offset); 2880 2881 return E_NOTIMPL; 2882 } 2883 2884 static HRESULT STDMETHODCALLTYPE debugcontrol_Disassemble(IDebugControl2 *iface, ULONG64 offset, ULONG flags, 2885 char *buffer, ULONG buffer_size, ULONG *disassm_size, ULONG64 *end_offset) 2886 { 2887 FIXME("%p, %s, %#x, %p, %u, %p, %p stub.\n", iface, wine_dbgstr_longlong(offset), flags, buffer, buffer_size, 2888 disassm_size, end_offset); 2889 2890 return E_NOTIMPL; 2891 } 2892 2893 static HRESULT STDMETHODCALLTYPE debugcontrol_GetDisassembleEffectiveOffset(IDebugControl2 *iface, ULONG64 *offset) 2894 { 2895 FIXME("%p, %p stub.\n", iface, offset); 2896 2897 return E_NOTIMPL; 2898 } 2899 2900 static HRESULT STDMETHODCALLTYPE debugcontrol_OutputDisassembly(IDebugControl2 *iface, ULONG output_control, 2901 ULONG64 offset, ULONG flags, ULONG64 *end_offset) 2902 { 2903 FIXME("%p, %u, %s, %#x, %p stub.\n", iface, output_control, wine_dbgstr_longlong(offset), flags, end_offset); 2904 2905 return E_NOTIMPL; 2906 } 2907 2908 static HRESULT STDMETHODCALLTYPE debugcontrol_OutputDisassemblyLines(IDebugControl2 *iface, ULONG output_control, 2909 ULONG prev_lines, ULONG total_lines, ULONG64 offset, ULONG flags, ULONG *offset_line, ULONG64 *start_offset, 2910 ULONG64 *end_offset, ULONG64 *line_offsets) 2911 { 2912 FIXME("%p, %u, %u, %u, %s, %#x, %p, %p, %p, %p stub.\n", iface, output_control, prev_lines, total_lines, 2913 wine_dbgstr_longlong(offset), flags, offset_line, start_offset, end_offset, line_offsets); 2914 2915 return E_NOTIMPL; 2916 } 2917 2918 static HRESULT STDMETHODCALLTYPE debugcontrol_GetNearInstruction(IDebugControl2 *iface, ULONG64 offset, LONG delta, 2919 ULONG64 *instr_offset) 2920 { 2921 FIXME("%p, %s, %d, %p stub.\n", iface, wine_dbgstr_longlong(offset), delta, instr_offset); 2922 2923 return E_NOTIMPL; 2924 } 2925 2926 static HRESULT STDMETHODCALLTYPE debugcontrol_GetStackTrace(IDebugControl2 *iface, ULONG64 frame_offset, 2927 ULONG64 stack_offset, ULONG64 instr_offset, DEBUG_STACK_FRAME *frames, ULONG frames_size, ULONG *frames_filled) 2928 { 2929 FIXME("%p, %s, %s, %s, %p, %u, %p stub.\n", iface, wine_dbgstr_longlong(frame_offset), 2930 wine_dbgstr_longlong(stack_offset), wine_dbgstr_longlong(instr_offset), frames, frames_size, frames_filled); 2931 2932 return E_NOTIMPL; 2933 } 2934 2935 static HRESULT STDMETHODCALLTYPE debugcontrol_GetReturnOffset(IDebugControl2 *iface, ULONG64 *offset) 2936 { 2937 FIXME("%p, %p stub.\n", iface, offset); 2938 2939 return E_NOTIMPL; 2940 } 2941 2942 static HRESULT STDMETHODCALLTYPE debugcontrol_OutputStackTrace(IDebugControl2 *iface, ULONG output_control, 2943 DEBUG_STACK_FRAME *frames, ULONG frames_size, ULONG flags) 2944 { 2945 FIXME("%p, %u, %p, %u, %#x stub.\n", iface, output_control, frames, frames_size, flags); 2946 2947 return E_NOTIMPL; 2948 } 2949 2950 static HRESULT STDMETHODCALLTYPE debugcontrol_GetDebuggeeType(IDebugControl2 *iface, ULONG *debug_class, 2951 ULONG *qualifier) 2952 { 2953 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 2954 static struct target_process *target; 2955 2956 FIXME("%p, %p, %p stub.\n", iface, debug_class, qualifier); 2957 2958 *debug_class = DEBUG_CLASS_UNINITIALIZED; 2959 *qualifier = 0; 2960 2961 if (!(target = debug_client_get_target(debug_client))) 2962 return E_UNEXPECTED; 2963 2964 *debug_class = DEBUG_CLASS_USER_WINDOWS; 2965 *qualifier = DEBUG_USER_WINDOWS_PROCESS; 2966 2967 return S_OK; 2968 } 2969 2970 static HRESULT STDMETHODCALLTYPE debugcontrol_GetActualProcessorType(IDebugControl2 *iface, ULONG *type) 2971 { 2972 FIXME("%p, %p stub.\n", iface, type); 2973 2974 return E_NOTIMPL; 2975 } 2976 2977 static HRESULT STDMETHODCALLTYPE debugcontrol_GetExecutingProcessorType(IDebugControl2 *iface, ULONG *type) 2978 { 2979 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 2980 static struct target_process *target; 2981 HRESULT hr; 2982 2983 TRACE("%p, %p.\n", iface, type); 2984 2985 if (!(target = debug_client_get_target(debug_client))) 2986 return E_UNEXPECTED; 2987 2988 if (FAILED(hr = debug_target_init_modules_info(target))) 2989 return hr; 2990 2991 *type = target->cpu_type; 2992 2993 return S_OK; 2994 } 2995 2996 static HRESULT STDMETHODCALLTYPE debugcontrol_GetNumberPossibleExecutingProcessorTypes(IDebugControl2 *iface, 2997 ULONG *count) 2998 { 2999 FIXME("%p, %p stub.\n", iface, count); 3000 3001 return E_NOTIMPL; 3002 } 3003 3004 static HRESULT STDMETHODCALLTYPE debugcontrol_GetPossibleExecutingProcessorTypes(IDebugControl2 *iface, ULONG start, 3005 ULONG count, ULONG *types) 3006 { 3007 FIXME("%p, %u, %u, %p stub.\n", iface, start, count, types); 3008 3009 return E_NOTIMPL; 3010 } 3011 3012 static HRESULT STDMETHODCALLTYPE debugcontrol_GetNumberProcessors(IDebugControl2 *iface, ULONG *count) 3013 { 3014 FIXME("%p, %p stub.\n", iface, count); 3015 3016 return E_NOTIMPL; 3017 } 3018 3019 static HRESULT STDMETHODCALLTYPE debugcontrol_GetSystemVersion(IDebugControl2 *iface, ULONG *platform_id, ULONG *major, 3020 ULONG *minor, char *sp_string, ULONG sp_string_size, ULONG *sp_string_used, ULONG *sp_number, 3021 char *build_string, ULONG build_string_size, ULONG *build_string_used) 3022 { 3023 FIXME("%p, %p, %p, %p, %p, %u, %p, %p, %p, %u, %p stub.\n", iface, platform_id, major, minor, sp_string, 3024 sp_string_size, sp_string_used, sp_number, build_string, build_string_size, build_string_used); 3025 3026 return E_NOTIMPL; 3027 } 3028 3029 static HRESULT STDMETHODCALLTYPE debugcontrol_GetPageSize(IDebugControl2 *iface, ULONG *size) 3030 { 3031 FIXME("%p, %p stub.\n", iface, size); 3032 3033 return E_NOTIMPL; 3034 } 3035 3036 static HRESULT STDMETHODCALLTYPE debugcontrol_IsPointer64Bit(IDebugControl2 *iface) 3037 { 3038 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 3039 static struct target_process *target; 3040 HRESULT hr; 3041 3042 TRACE("%p.\n", iface); 3043 3044 if (!(target = debug_client_get_target(debug_client))) 3045 return E_UNEXPECTED; 3046 3047 if (FAILED(hr = debug_target_init_modules_info(target))) 3048 return hr; 3049 3050 switch (target->cpu_type) 3051 { 3052 case IMAGE_FILE_MACHINE_I386: 3053 case IMAGE_FILE_MACHINE_ARM: 3054 hr = S_FALSE; 3055 break; 3056 case IMAGE_FILE_MACHINE_IA64: 3057 case IMAGE_FILE_MACHINE_AMD64: 3058 case IMAGE_FILE_MACHINE_ARM64: 3059 hr = S_OK; 3060 break; 3061 default: 3062 FIXME("Unexpected cpu type %#x.\n", target->cpu_type); 3063 hr = E_UNEXPECTED; 3064 } 3065 3066 return hr; 3067 } 3068 3069 static HRESULT STDMETHODCALLTYPE debugcontrol_ReadBugCheckData(IDebugControl2 *iface, ULONG *code, ULONG64 *arg1, 3070 ULONG64 *arg2, ULONG64 *arg3, ULONG64 *arg4) 3071 { 3072 FIXME("%p, %p, %p, %p, %p, %p stub.\n", iface, code, arg1, arg2, arg3, arg4); 3073 3074 return E_NOTIMPL; 3075 } 3076 3077 static HRESULT STDMETHODCALLTYPE debugcontrol_GetNumberSupportedProcessorTypes(IDebugControl2 *iface, ULONG *count) 3078 { 3079 FIXME("%p, %p stub.\n", iface, count); 3080 3081 return E_NOTIMPL; 3082 } 3083 3084 static HRESULT STDMETHODCALLTYPE debugcontrol_GetSupportedProcessorTypes(IDebugControl2 *iface, ULONG start, 3085 ULONG count, ULONG *types) 3086 { 3087 FIXME("%p, %u, %u, %p stub.\n", iface, start, count, types); 3088 3089 return E_NOTIMPL; 3090 } 3091 3092 static HRESULT STDMETHODCALLTYPE debugcontrol_GetProcessorTypeNames(IDebugControl2 *iface, ULONG type, char *full_name, 3093 ULONG full_name_buffer_size, ULONG *full_name_size, char *abbrev_name, ULONG abbrev_name_buffer_size, 3094 ULONG *abbrev_name_size) 3095 { 3096 FIXME("%p, %u, %p, %u, %p, %p, %u, %p stub.\n", iface, type, full_name, full_name_buffer_size, full_name_size, 3097 abbrev_name, abbrev_name_buffer_size, abbrev_name_size); 3098 3099 return E_NOTIMPL; 3100 } 3101 3102 static HRESULT STDMETHODCALLTYPE debugcontrol_GetEffectiveProcessorType(IDebugControl2 *iface, ULONG *type) 3103 { 3104 FIXME("%p, %p stub.\n", iface, type); 3105 3106 return E_NOTIMPL; 3107 } 3108 3109 static HRESULT STDMETHODCALLTYPE debugcontrol_SetEffectiveProcessorType(IDebugControl2 *iface, ULONG type) 3110 { 3111 FIXME("%p, %u stub.\n", iface, type); 3112 3113 return E_NOTIMPL; 3114 } 3115 3116 static HRESULT STDMETHODCALLTYPE debugcontrol_GetExecutionStatus(IDebugControl2 *iface, ULONG *status) 3117 { 3118 FIXME("%p, %p stub.\n", iface, status); 3119 3120 return E_NOTIMPL; 3121 } 3122 3123 static HRESULT STDMETHODCALLTYPE debugcontrol_SetExecutionStatus(IDebugControl2 *iface, ULONG status) 3124 { 3125 FIXME("%p, %u stub.\n", iface, status); 3126 3127 return E_NOTIMPL; 3128 } 3129 3130 static HRESULT STDMETHODCALLTYPE debugcontrol_GetCodeLevel(IDebugControl2 *iface, ULONG *level) 3131 { 3132 FIXME("%p, %p stub.\n", iface, level); 3133 3134 return E_NOTIMPL; 3135 } 3136 3137 static HRESULT STDMETHODCALLTYPE debugcontrol_SetCodeLevel(IDebugControl2 *iface, ULONG level) 3138 { 3139 FIXME("%p, %u stub.\n", iface, level); 3140 3141 return E_NOTIMPL; 3142 } 3143 3144 static HRESULT STDMETHODCALLTYPE debugcontrol_GetEngineOptions(IDebugControl2 *iface, ULONG *options) 3145 { 3146 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 3147 3148 TRACE("%p, %p.\n", iface, options); 3149 3150 *options = debug_client->engine_options; 3151 3152 return S_OK; 3153 } 3154 3155 static HRESULT STDMETHODCALLTYPE debugcontrol_AddEngineOptions(IDebugControl2 *iface, ULONG options) 3156 { 3157 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 3158 3159 TRACE("%p, %#x.\n", iface, options); 3160 3161 if (options & ~DEBUG_ENGOPT_ALL) 3162 return E_INVALIDARG; 3163 3164 debug_client->engine_options |= options; 3165 3166 return S_OK; 3167 } 3168 3169 static HRESULT STDMETHODCALLTYPE debugcontrol_RemoveEngineOptions(IDebugControl2 *iface, ULONG options) 3170 { 3171 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 3172 3173 TRACE("%p, %#x.\n", iface, options); 3174 3175 debug_client->engine_options &= ~options; 3176 3177 return S_OK; 3178 } 3179 3180 static HRESULT STDMETHODCALLTYPE debugcontrol_SetEngineOptions(IDebugControl2 *iface, ULONG options) 3181 { 3182 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 3183 3184 TRACE("%p, %#x.\n", iface, options); 3185 3186 if (options & ~DEBUG_ENGOPT_ALL) 3187 return E_INVALIDARG; 3188 3189 debug_client->engine_options = options; 3190 3191 return S_OK; 3192 } 3193 3194 static HRESULT STDMETHODCALLTYPE debugcontrol_GetSystemErrorControl(IDebugControl2 *iface, ULONG *output_level, 3195 ULONG *break_level) 3196 { 3197 FIXME("%p, %p, %p stub.\n", iface, output_level, break_level); 3198 3199 return E_NOTIMPL; 3200 } 3201 3202 static HRESULT STDMETHODCALLTYPE debugcontrol_SetSystemErrorControl(IDebugControl2 *iface, ULONG output_level, 3203 ULONG break_level) 3204 { 3205 FIXME("%p, %u, %u stub.\n", iface, output_level, break_level); 3206 3207 return E_NOTIMPL; 3208 } 3209 3210 static HRESULT STDMETHODCALLTYPE debugcontrol_GetTextMacro(IDebugControl2 *iface, ULONG slot, char *buffer, 3211 ULONG buffer_size, ULONG *macro_size) 3212 { 3213 FIXME("%p, %u, %p, %u, %p stub.\n", iface, slot, buffer, buffer_size, macro_size); 3214 3215 return E_NOTIMPL; 3216 } 3217 3218 static HRESULT STDMETHODCALLTYPE debugcontrol_SetTextMacro(IDebugControl2 *iface, ULONG slot, const char *macro) 3219 { 3220 FIXME("%p, %u, %s stub.\n", iface, slot, debugstr_a(macro)); 3221 3222 return E_NOTIMPL; 3223 } 3224 3225 static HRESULT STDMETHODCALLTYPE debugcontrol_GetRadix(IDebugControl2 *iface, ULONG *radix) 3226 { 3227 FIXME("%p, %p stub.\n", iface, radix); 3228 3229 return E_NOTIMPL; 3230 } 3231 3232 static HRESULT STDMETHODCALLTYPE debugcontrol_SetRadix(IDebugControl2 *iface, ULONG radix) 3233 { 3234 FIXME("%p, %u stub.\n", iface, radix); 3235 3236 return E_NOTIMPL; 3237 } 3238 3239 static HRESULT STDMETHODCALLTYPE debugcontrol_Evaluate(IDebugControl2 *iface, const char *expression, 3240 ULONG desired_type, DEBUG_VALUE *value, ULONG *remainder_index) 3241 { 3242 FIXME("%p, %s, %u, %p, %p stub.\n", iface, debugstr_a(expression), desired_type, value, remainder_index); 3243 3244 return E_NOTIMPL; 3245 } 3246 3247 static HRESULT STDMETHODCALLTYPE debugcontrol_CoerceValue(IDebugControl2 *iface, DEBUG_VALUE input, ULONG output_type, 3248 DEBUG_VALUE *output) 3249 { 3250 FIXME("%p, %u, %p stub.\n", iface, output_type, output); 3251 3252 return E_NOTIMPL; 3253 } 3254 3255 static HRESULT STDMETHODCALLTYPE debugcontrol_CoerceValues(IDebugControl2 *iface, ULONG count, DEBUG_VALUE *input, 3256 ULONG *output_types, DEBUG_VALUE *output) 3257 { 3258 FIXME("%p, %u, %p, %p, %p stub.\n", iface, count, input, output_types, output); 3259 3260 return E_NOTIMPL; 3261 } 3262 3263 static HRESULT STDMETHODCALLTYPE debugcontrol_Execute(IDebugControl2 *iface, ULONG output_control, const char *command, 3264 ULONG flags) 3265 { 3266 FIXME("%p, %u, %s, %#x stub.\n", iface, output_control, debugstr_a(command), flags); 3267 3268 return E_NOTIMPL; 3269 } 3270 3271 static HRESULT STDMETHODCALLTYPE debugcontrol_ExecuteCommandFile(IDebugControl2 *iface, ULONG output_control, 3272 const char *command_file, ULONG flags) 3273 { 3274 FIXME("%p, %u, %s, %#x stub.\n", iface, output_control, debugstr_a(command_file), flags); 3275 3276 return E_NOTIMPL; 3277 } 3278 3279 static HRESULT STDMETHODCALLTYPE debugcontrol_GetNumberBreakpoints(IDebugControl2 *iface, ULONG *count) 3280 { 3281 FIXME("%p, %p stub.\n", iface, count); 3282 3283 return E_NOTIMPL; 3284 } 3285 3286 static HRESULT STDMETHODCALLTYPE debugcontrol_GetBreakpointByIndex(IDebugControl2 *iface, ULONG index, 3287 IDebugBreakpoint **bp) 3288 { 3289 FIXME("%p, %u, %p stub.\n", iface, index, bp); 3290 3291 return E_NOTIMPL; 3292 } 3293 3294 static HRESULT STDMETHODCALLTYPE debugcontrol_GetBreakpointById(IDebugControl2 *iface, ULONG id, IDebugBreakpoint **bp) 3295 { 3296 FIXME("%p, %u, %p stub.\n", iface, id, bp); 3297 3298 return E_NOTIMPL; 3299 } 3300 3301 static HRESULT STDMETHODCALLTYPE debugcontrol_GetBreakpointParameters(IDebugControl2 *iface, ULONG count, ULONG *ids, 3302 ULONG start, DEBUG_BREAKPOINT_PARAMETERS *parameters) 3303 { 3304 FIXME("%p, %u, %p, %u, %p stub.\n", iface, count, ids, start, parameters); 3305 3306 return E_NOTIMPL; 3307 } 3308 3309 static HRESULT STDMETHODCALLTYPE debugcontrol_AddBreakpoint(IDebugControl2 *iface, ULONG type, ULONG desired_id, 3310 IDebugBreakpoint **bp) 3311 { 3312 FIXME("%p, %u, %u, %p stub.\n", iface, type, desired_id, bp); 3313 3314 return E_NOTIMPL; 3315 } 3316 3317 static HRESULT STDMETHODCALLTYPE debugcontrol_RemoveBreakpoint(IDebugControl2 *iface, IDebugBreakpoint *bp) 3318 { 3319 FIXME("%p, %p stub.\n", iface, bp); 3320 3321 return E_NOTIMPL; 3322 } 3323 3324 static HRESULT STDMETHODCALLTYPE debugcontrol_AddExtension(IDebugControl2 *iface, const char *path, ULONG flags, 3325 ULONG64 *handle) 3326 { 3327 FIXME("%p, %s, %#x, %p stub.\n", iface, debugstr_a(path), flags, handle); 3328 3329 return E_NOTIMPL; 3330 } 3331 3332 static HRESULT STDMETHODCALLTYPE debugcontrol_RemoveExtension(IDebugControl2 *iface, ULONG64 handle) 3333 { 3334 FIXME("%p, %s stub.\n", iface, wine_dbgstr_longlong(handle)); 3335 3336 return E_NOTIMPL; 3337 } 3338 3339 static HRESULT STDMETHODCALLTYPE debugcontrol_GetExtensionByPath(IDebugControl2 *iface, const char *path, 3340 ULONG64 *handle) 3341 { 3342 FIXME("%p, %s, %p stub.\n", iface, debugstr_a(path), handle); 3343 3344 return E_NOTIMPL; 3345 } 3346 3347 static HRESULT STDMETHODCALLTYPE debugcontrol_CallExtension(IDebugControl2 *iface, ULONG64 handle, 3348 const char *function, const char *args) 3349 { 3350 FIXME("%p, %s, %s, %s stub.\n", iface, wine_dbgstr_longlong(handle), debugstr_a(function), debugstr_a(args)); 3351 3352 return E_NOTIMPL; 3353 } 3354 3355 static HRESULT STDMETHODCALLTYPE debugcontrol_GetExtensionFunction(IDebugControl2 *iface, ULONG64 handle, 3356 const char *name, void *function) 3357 { 3358 FIXME("%p, %s, %s, %p stub.\n", iface, wine_dbgstr_longlong(handle), debugstr_a(name), function); 3359 3360 return E_NOTIMPL; 3361 } 3362 3363 static HRESULT STDMETHODCALLTYPE debugcontrol_GetWindbgExtensionApis32(IDebugControl2 *iface, 3364 PWINDBG_EXTENSION_APIS32 api) 3365 { 3366 FIXME("%p, %p stub.\n", iface, api); 3367 3368 return E_NOTIMPL; 3369 } 3370 3371 static HRESULT STDMETHODCALLTYPE debugcontrol_GetWindbgExtensionApis64(IDebugControl2 *iface, 3372 PWINDBG_EXTENSION_APIS64 api) 3373 { 3374 FIXME("%p, %p stub.\n", iface, api); 3375 3376 return E_NOTIMPL; 3377 } 3378 3379 static HRESULT STDMETHODCALLTYPE debugcontrol_GetNumberEventFilters(IDebugControl2 *iface, ULONG *specific_events, 3380 ULONG *specific_exceptions, ULONG *arbitrary_exceptions) 3381 { 3382 FIXME("%p, %p, %p, %p stub.\n", iface, specific_events, specific_exceptions, arbitrary_exceptions); 3383 3384 return E_NOTIMPL; 3385 } 3386 3387 static HRESULT STDMETHODCALLTYPE debugcontrol_GetEventFilterText(IDebugControl2 *iface, ULONG index, char *buffer, 3388 ULONG buffer_size, ULONG *text_size) 3389 { 3390 FIXME("%p, %u, %p, %u, %p stub.\n", iface, index, buffer, buffer_size, text_size); 3391 3392 return E_NOTIMPL; 3393 } 3394 3395 static HRESULT STDMETHODCALLTYPE debugcontrol_GetEventFilterCommand(IDebugControl2 *iface, ULONG index, char *buffer, 3396 ULONG buffer_size, ULONG *command_size) 3397 { 3398 FIXME("%p, %u, %p, %u, %p stub.\n", iface, index, buffer, buffer_size, command_size); 3399 3400 return E_NOTIMPL; 3401 } 3402 3403 static HRESULT STDMETHODCALLTYPE debugcontrol_SetEventFilterCommand(IDebugControl2 *iface, ULONG index, 3404 const char *command) 3405 { 3406 FIXME("%p, %u, %s stub.\n", iface, index, debugstr_a(command)); 3407 3408 return E_NOTIMPL; 3409 } 3410 3411 static HRESULT STDMETHODCALLTYPE debugcontrol_GetSpecificFilterParameters(IDebugControl2 *iface, ULONG start, 3412 ULONG count, DEBUG_SPECIFIC_FILTER_PARAMETERS *parameters) 3413 { 3414 FIXME("%p, %u, %u, %p stub.\n", iface, start, count, parameters); 3415 3416 return E_NOTIMPL; 3417 } 3418 3419 static HRESULT STDMETHODCALLTYPE debugcontrol_SetSpecificFilterParameters(IDebugControl2 *iface, ULONG start, 3420 ULONG count, DEBUG_SPECIFIC_FILTER_PARAMETERS *parameters) 3421 { 3422 FIXME("%p, %u, %u, %p stub.\n", iface, start, count, parameters); 3423 3424 return E_NOTIMPL; 3425 } 3426 3427 static HRESULT STDMETHODCALLTYPE debugcontrol_GetSpecificFilterArgument(IDebugControl2 *iface, ULONG index, 3428 char *buffer, ULONG buffer_size, ULONG *argument_size) 3429 { 3430 FIXME("%p, %u, %p, %u, %p stub.\n", iface, index, buffer, buffer_size, argument_size); 3431 3432 return E_NOTIMPL; 3433 } 3434 3435 static HRESULT STDMETHODCALLTYPE debugcontrol_SetSpecificFilterArgument(IDebugControl2 *iface, ULONG index, 3436 const char *argument) 3437 { 3438 FIXME("%p, %u, %s stub.\n", iface, index, debugstr_a(argument)); 3439 3440 return E_NOTIMPL; 3441 } 3442 3443 static HRESULT STDMETHODCALLTYPE debugcontrol_GetExceptionFilterParameters(IDebugControl2 *iface, ULONG count, 3444 ULONG *codes, ULONG start, DEBUG_EXCEPTION_FILTER_PARAMETERS *parameters) 3445 { 3446 FIXME("%p, %u, %p, %u, %p stub.\n", iface, count, codes, start, parameters); 3447 3448 return E_NOTIMPL; 3449 } 3450 3451 static HRESULT STDMETHODCALLTYPE debugcontrol_SetExceptionFilterParameters(IDebugControl2 *iface, ULONG count, 3452 DEBUG_EXCEPTION_FILTER_PARAMETERS *parameters) 3453 { 3454 FIXME("%p, %u, %p stub.\n", iface, count, parameters); 3455 3456 return E_NOTIMPL; 3457 } 3458 3459 static HRESULT STDMETHODCALLTYPE debugcontrol_GetExceptionFilterSecondCommand(IDebugControl2 *iface, ULONG index, 3460 char *buffer, ULONG buffer_size, ULONG *command_size) 3461 { 3462 FIXME("%p, %u, %p, %u, %p stub.\n", iface, index, buffer, buffer_size, command_size); 3463 3464 return E_NOTIMPL; 3465 } 3466 3467 static HRESULT STDMETHODCALLTYPE debugcontrol_SetExceptionFilterSecondCommand(IDebugControl2 *iface, ULONG index, 3468 const char *command) 3469 { 3470 FIXME("%p, %u, %s stub.\n", iface, index, debugstr_a(command)); 3471 3472 return E_NOTIMPL; 3473 } 3474 3475 static HRESULT STDMETHODCALLTYPE debugcontrol_WaitForEvent(IDebugControl2 *iface, ULONG flags, ULONG timeout) 3476 { 3477 struct debug_client *debug_client = impl_from_IDebugControl2(iface); 3478 struct target_process *target; 3479 3480 TRACE("%p, %#x, %u.\n", iface, flags, timeout); 3481 3482 /* FIXME: only one target is used currently */ 3483 3484 if (!(target = debug_client_get_target(debug_client))) 3485 return E_UNEXPECTED; 3486 3487 if (target->attach_flags & DEBUG_ATTACH_NONINVASIVE) 3488 { 3489 BOOL suspend = !(target->attach_flags & DEBUG_ATTACH_NONINVASIVE_NO_SUSPEND); 3490 DWORD access = PROCESS_VM_READ | PROCESS_VM_WRITE | PROCESS_QUERY_LIMITED_INFORMATION; 3491 NTSTATUS status; 3492 3493 if (suspend) 3494 access |= PROCESS_SUSPEND_RESUME; 3495 3496 target->handle = OpenProcess(access, FALSE, target->pid); 3497 if (!target->handle) 3498 { 3499 WARN("Failed to get process handle for pid %#x.\n", target->pid); 3500 return E_UNEXPECTED; 3501 } 3502 3503 if (suspend) 3504 { 3505 status = NtSuspendProcess(target->handle); 3506 if (status) 3507 WARN("Failed to suspend a process, status %#x.\n", status); 3508 } 3509 3510 return S_OK; 3511 } 3512 else 3513 { 3514 FIXME("Unsupported attach flags %#x.\n", target->attach_flags); 3515 } 3516 3517 return E_NOTIMPL; 3518 } 3519 3520 static HRESULT STDMETHODCALLTYPE debugcontrol_GetLastEventInformation(IDebugControl2 *iface, ULONG *type, ULONG *pid, 3521 ULONG *tid, void *extra_info, ULONG extra_info_size, ULONG *extra_info_used, char *description, 3522 ULONG desc_size, ULONG *desc_used) 3523 { 3524 FIXME("%p, %p, %p, %p, %p, %u, %p, %p, %u, %p stub.\n", iface, type, pid, tid, extra_info, extra_info_size, 3525 extra_info_used, description, desc_size, desc_used); 3526 3527 return E_NOTIMPL; 3528 } 3529 3530 static HRESULT STDMETHODCALLTYPE debugcontrol_GetCurrentTimeDate(IDebugControl2 *iface, ULONG timedate) 3531 { 3532 FIXME("%p, %u stub.\n", iface, timedate); 3533 3534 return E_NOTIMPL; 3535 } 3536 3537 static HRESULT STDMETHODCALLTYPE debugcontrol_GetCurrentSystemUpTime(IDebugControl2 *iface, ULONG uptime) 3538 { 3539 FIXME("%p, %u stub.\n", iface, uptime); 3540 3541 return E_NOTIMPL; 3542 } 3543 3544 static HRESULT STDMETHODCALLTYPE debugcontrol_GetDumpFormatFlags(IDebugControl2 *iface, ULONG *flags) 3545 { 3546 FIXME("%p, %p stub.\n", iface, flags); 3547 3548 return E_NOTIMPL; 3549 } 3550 3551 static HRESULT STDMETHODCALLTYPE debugcontrol_GetNumberTextPlacements(IDebugControl2 *iface, ULONG *count) 3552 { 3553 FIXME("%p, %p stub.\n", iface, count); 3554 3555 return E_NOTIMPL; 3556 } 3557 3558 static HRESULT STDMETHODCALLTYPE debugcontrol_GetNumberTextReplacement(IDebugControl2 *iface, const char *src_text, 3559 ULONG index, char *src_buffer, ULONG src_buffer_size, ULONG *src_size, char *dst_buffer, 3560 ULONG dst_buffer_size, ULONG *dst_size) 3561 { 3562 FIXME("%p, %s, %u, %p, %u, %p, %p, %u, %p stub.\n", iface, debugstr_a(src_text), index, src_buffer, 3563 src_buffer_size, src_size, dst_buffer, dst_buffer_size, dst_size); 3564 3565 return E_NOTIMPL; 3566 } 3567 3568 static HRESULT STDMETHODCALLTYPE debugcontrol_SetTextReplacement(IDebugControl2 *iface, const char *src_text, 3569 const char *dst_text) 3570 { 3571 FIXME("%p, %s, %s stub.\n", iface, debugstr_a(src_text), debugstr_a(dst_text)); 3572 3573 return E_NOTIMPL; 3574 } 3575 3576 static HRESULT STDMETHODCALLTYPE debugcontrol_RemoveTextReplacements(IDebugControl2 *iface) 3577 { 3578 FIXME("%p stub.\n", iface); 3579 3580 return E_NOTIMPL; 3581 } 3582 3583 static HRESULT STDMETHODCALLTYPE debugcontrol_OutputTextReplacements(IDebugControl2 *iface, ULONG output_control, 3584 ULONG flags) 3585 { 3586 FIXME("%p, %u, %#x stub.\n", iface, output_control, flags); 3587 3588 return E_NOTIMPL; 3589 } 3590 3591 static const IDebugControl2Vtbl debugcontrolvtbl = 3592 { 3593 debugcontrol_QueryInterface, 3594 debugcontrol_AddRef, 3595 debugcontrol_Release, 3596 debugcontrol_GetInterrupt, 3597 debugcontrol_SetInterrupt, 3598 debugcontrol_GetInterruptTimeout, 3599 debugcontrol_SetInterruptTimeout, 3600 debugcontrol_GetLogFile, 3601 debugcontrol_OpenLogFile, 3602 debugcontrol_CloseLogFile, 3603 debugcontrol_GetLogMask, 3604 debugcontrol_SetLogMask, 3605 debugcontrol_Input, 3606 debugcontrol_ReturnInput, 3607 debugcontrol_Output, 3608 debugcontrol_OutputVaList, 3609 debugcontrol_ControlledOutput, 3610 debugcontrol_ControlledOutputVaList, 3611 debugcontrol_OutputPrompt, 3612 debugcontrol_OutputPromptVaList, 3613 debugcontrol_GetPromptText, 3614 debugcontrol_OutputCurrentState, 3615 debugcontrol_OutputVersionInformation, 3616 debugcontrol_GetNotifyEventHandle, 3617 debugcontrol_SetNotifyEventHandle, 3618 debugcontrol_Assemble, 3619 debugcontrol_Disassemble, 3620 debugcontrol_GetDisassembleEffectiveOffset, 3621 debugcontrol_OutputDisassembly, 3622 debugcontrol_OutputDisassemblyLines, 3623 debugcontrol_GetNearInstruction, 3624 debugcontrol_GetStackTrace, 3625 debugcontrol_GetReturnOffset, 3626 debugcontrol_OutputStackTrace, 3627 debugcontrol_GetDebuggeeType, 3628 debugcontrol_GetActualProcessorType, 3629 debugcontrol_GetExecutingProcessorType, 3630 debugcontrol_GetNumberPossibleExecutingProcessorTypes, 3631 debugcontrol_GetPossibleExecutingProcessorTypes, 3632 debugcontrol_GetNumberProcessors, 3633 debugcontrol_GetSystemVersion, 3634 debugcontrol_GetPageSize, 3635 debugcontrol_IsPointer64Bit, 3636 debugcontrol_ReadBugCheckData, 3637 debugcontrol_GetNumberSupportedProcessorTypes, 3638 debugcontrol_GetSupportedProcessorTypes, 3639 debugcontrol_GetProcessorTypeNames, 3640 debugcontrol_GetEffectiveProcessorType, 3641 debugcontrol_SetEffectiveProcessorType, 3642 debugcontrol_GetExecutionStatus, 3643 debugcontrol_SetExecutionStatus, 3644 debugcontrol_GetCodeLevel, 3645 debugcontrol_SetCodeLevel, 3646 debugcontrol_GetEngineOptions, 3647 debugcontrol_AddEngineOptions, 3648 debugcontrol_RemoveEngineOptions, 3649 debugcontrol_SetEngineOptions, 3650 debugcontrol_GetSystemErrorControl, 3651 debugcontrol_SetSystemErrorControl, 3652 debugcontrol_GetTextMacro, 3653 debugcontrol_SetTextMacro, 3654 debugcontrol_GetRadix, 3655 debugcontrol_SetRadix, 3656 debugcontrol_Evaluate, 3657 debugcontrol_CoerceValue, 3658 debugcontrol_CoerceValues, 3659 debugcontrol_Execute, 3660 debugcontrol_ExecuteCommandFile, 3661 debugcontrol_GetNumberBreakpoints, 3662 debugcontrol_GetBreakpointByIndex, 3663 debugcontrol_GetBreakpointById, 3664 debugcontrol_GetBreakpointParameters, 3665 debugcontrol_AddBreakpoint, 3666 debugcontrol_RemoveBreakpoint, 3667 debugcontrol_AddExtension, 3668 debugcontrol_RemoveExtension, 3669 debugcontrol_GetExtensionByPath, 3670 debugcontrol_CallExtension, 3671 debugcontrol_GetExtensionFunction, 3672 debugcontrol_GetWindbgExtensionApis32, 3673 debugcontrol_GetWindbgExtensionApis64, 3674 debugcontrol_GetNumberEventFilters, 3675 debugcontrol_GetEventFilterText, 3676 debugcontrol_GetEventFilterCommand, 3677 debugcontrol_SetEventFilterCommand, 3678 debugcontrol_GetSpecificFilterParameters, 3679 debugcontrol_SetSpecificFilterParameters, 3680 debugcontrol_GetSpecificFilterArgument, 3681 debugcontrol_SetSpecificFilterArgument, 3682 debugcontrol_GetExceptionFilterParameters, 3683 debugcontrol_SetExceptionFilterParameters, 3684 debugcontrol_GetExceptionFilterSecondCommand, 3685 debugcontrol_SetExceptionFilterSecondCommand, 3686 debugcontrol_WaitForEvent, 3687 debugcontrol_GetLastEventInformation, 3688 debugcontrol_GetCurrentTimeDate, 3689 debugcontrol_GetCurrentSystemUpTime, 3690 debugcontrol_GetDumpFormatFlags, 3691 debugcontrol_GetNumberTextPlacements, 3692 debugcontrol_GetNumberTextReplacement, 3693 debugcontrol_SetTextReplacement, 3694 debugcontrol_RemoveTextReplacements, 3695 debugcontrol_OutputTextReplacements, 3696 }; 3697 3698 static HRESULT STDMETHODCALLTYPE debugadvanced_QueryInterface(IDebugAdvanced *iface, REFIID riid, void **obj) 3699 { 3700 struct debug_client *debug_client = impl_from_IDebugAdvanced(iface); 3701 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 3702 return IUnknown_QueryInterface(unk, riid, obj); 3703 } 3704 3705 static ULONG STDMETHODCALLTYPE debugadvanced_AddRef(IDebugAdvanced *iface) 3706 { 3707 struct debug_client *debug_client = impl_from_IDebugAdvanced(iface); 3708 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 3709 return IUnknown_AddRef(unk); 3710 } 3711 3712 static ULONG STDMETHODCALLTYPE debugadvanced_Release(IDebugAdvanced *iface) 3713 { 3714 struct debug_client *debug_client = impl_from_IDebugAdvanced(iface); 3715 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 3716 return IUnknown_Release(unk); 3717 } 3718 3719 static HRESULT STDMETHODCALLTYPE debugadvanced_GetThreadContext(IDebugAdvanced *iface, void *context, 3720 ULONG context_size) 3721 { 3722 FIXME("%p, %p, %u stub.\n", iface, context, context_size); 3723 3724 return E_NOTIMPL; 3725 } 3726 3727 static HRESULT STDMETHODCALLTYPE debugadvanced_SetThreadContext(IDebugAdvanced *iface, void *context, 3728 ULONG context_size) 3729 { 3730 FIXME("%p, %p, %u stub.\n", iface, context, context_size); 3731 3732 return E_NOTIMPL; 3733 } 3734 3735 static const IDebugAdvancedVtbl debugadvancedvtbl = 3736 { 3737 debugadvanced_QueryInterface, 3738 debugadvanced_AddRef, 3739 debugadvanced_Release, 3740 /* IDebugAdvanced */ 3741 debugadvanced_GetThreadContext, 3742 debugadvanced_SetThreadContext, 3743 }; 3744 3745 3746 static HRESULT STDMETHODCALLTYPE debugsystemobjects_QueryInterface(IDebugSystemObjects *iface, REFIID riid, void **obj) 3747 { 3748 struct debug_client *debug_client = impl_from_IDebugSystemObjects(iface); 3749 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 3750 return IUnknown_QueryInterface(unk, riid, obj); 3751 } 3752 3753 static ULONG STDMETHODCALLTYPE debugsystemobjects_AddRef(IDebugSystemObjects *iface) 3754 { 3755 struct debug_client *debug_client = impl_from_IDebugSystemObjects(iface); 3756 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 3757 return IUnknown_AddRef(unk); 3758 } 3759 3760 static ULONG STDMETHODCALLTYPE debugsystemobjects_Release(IDebugSystemObjects *iface) 3761 { 3762 struct debug_client *debug_client = impl_from_IDebugSystemObjects(iface); 3763 IUnknown *unk = (IUnknown *)&debug_client->IDebugClient_iface; 3764 return IUnknown_Release(unk); 3765 } 3766 3767 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetEventThread(IDebugSystemObjects *iface, ULONG *id) 3768 { 3769 FIXME("%p, %p stub.\n", iface, id); 3770 3771 return E_NOTIMPL; 3772 } 3773 3774 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetEventProcess(IDebugSystemObjects *iface, ULONG *id) 3775 { 3776 FIXME("%p, %p stub.\n", iface, id); 3777 3778 return E_NOTIMPL; 3779 } 3780 3781 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetCurrentThreadId(IDebugSystemObjects *iface, ULONG *id) 3782 { 3783 FIXME("%p, %p stub.\n", iface, id); 3784 3785 return E_NOTIMPL; 3786 } 3787 3788 static HRESULT STDMETHODCALLTYPE debugsystemobjects_SetCurrentThreadId(IDebugSystemObjects *iface, ULONG id) 3789 { 3790 FIXME("%p, %u stub.\n", iface, id); 3791 3792 return E_NOTIMPL; 3793 } 3794 3795 static HRESULT STDMETHODCALLTYPE debugsystemobjects_SetCurrentProcessId(IDebugSystemObjects *iface, ULONG id) 3796 { 3797 FIXME("%p, %u stub.\n", iface, id); 3798 3799 return E_NOTIMPL; 3800 } 3801 3802 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetNumberThreads(IDebugSystemObjects *iface, ULONG *number) 3803 { 3804 FIXME("%p, %p stub.\n", iface, number); 3805 3806 return E_NOTIMPL; 3807 } 3808 3809 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetTotalNumberThreads(IDebugSystemObjects *iface, ULONG *total, 3810 ULONG *largest_process) 3811 { 3812 FIXME("%p, %p, %p stub.\n", iface, total, largest_process); 3813 3814 return E_NOTIMPL; 3815 } 3816 3817 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetThreadIdsByIndex(IDebugSystemObjects *iface, ULONG start, 3818 ULONG count, ULONG *ids, ULONG *sysids) 3819 { 3820 FIXME("%p, %u, %u, %p, %p stub.\n", iface, start, count, ids, sysids); 3821 3822 return E_NOTIMPL; 3823 } 3824 3825 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetThreadIdByProcessor(IDebugSystemObjects *iface, ULONG processor, 3826 ULONG *id) 3827 { 3828 FIXME("%p, %u, %p stub.\n", iface, processor, id); 3829 3830 return E_NOTIMPL; 3831 } 3832 3833 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetCurrentThreadDataOffset(IDebugSystemObjects *iface, 3834 ULONG64 *offset) 3835 { 3836 FIXME("%p, %p stub.\n", iface, offset); 3837 3838 return E_NOTIMPL; 3839 } 3840 3841 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetThreadIdByDataOffset(IDebugSystemObjects *iface, ULONG64 offset, 3842 ULONG *id) 3843 { 3844 FIXME("%p, %s, %p stub.\n", iface, wine_dbgstr_longlong(offset), id); 3845 3846 return E_NOTIMPL; 3847 } 3848 3849 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetCurrentThreadTeb(IDebugSystemObjects *iface, ULONG64 *offset) 3850 { 3851 FIXME("%p, %p stub.\n", iface, offset); 3852 3853 return E_NOTIMPL; 3854 } 3855 3856 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetThreadIdByTeb(IDebugSystemObjects *iface, ULONG64 offset, 3857 ULONG *id) 3858 { 3859 FIXME("%p, %s, %p stub.\n", iface, wine_dbgstr_longlong(offset), id); 3860 3861 return E_NOTIMPL; 3862 } 3863 3864 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetCurrentThreadSystemId(IDebugSystemObjects *iface, ULONG *sysid) 3865 { 3866 FIXME("%p, %p stub.\n", iface, sysid); 3867 3868 return E_NOTIMPL; 3869 } 3870 3871 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetThreadIdBySystemId(IDebugSystemObjects *iface, ULONG sysid, 3872 ULONG *id) 3873 { 3874 FIXME("%p, %u, %p stub.\n", iface, sysid, id); 3875 3876 return E_NOTIMPL; 3877 } 3878 3879 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetCurrentThreadHandle(IDebugSystemObjects *iface, ULONG64 *handle) 3880 { 3881 FIXME("%p, %p stub.\n", iface, handle); 3882 3883 return E_NOTIMPL; 3884 } 3885 3886 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetThreadIdByHandle(IDebugSystemObjects *iface, ULONG64 handle, 3887 ULONG *id) 3888 { 3889 FIXME("%p, %s, %p stub.\n", iface, wine_dbgstr_longlong(handle), id); 3890 3891 return E_NOTIMPL; 3892 } 3893 3894 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetNumberProcesses(IDebugSystemObjects *iface, ULONG *number) 3895 { 3896 FIXME("%p, %p stub.\n", iface, number); 3897 3898 return E_NOTIMPL; 3899 } 3900 3901 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetProcessIdsByIndex(IDebugSystemObjects *iface, ULONG start, 3902 ULONG count, ULONG *ids, ULONG *sysids) 3903 { 3904 FIXME("%p, %u, %u, %p, %p stub.\n", iface, start, count, ids, sysids); 3905 3906 return E_NOTIMPL; 3907 } 3908 3909 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetCurrentProcessDataOffset(IDebugSystemObjects *iface, 3910 ULONG64 *offset) 3911 { 3912 FIXME("%p, %p stub.\n", iface, offset); 3913 3914 return E_NOTIMPL; 3915 } 3916 3917 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetProcessIdByDataOffset(IDebugSystemObjects *iface, 3918 ULONG64 offset, ULONG *id) 3919 { 3920 FIXME("%p, %s, %p stub.\n", iface, wine_dbgstr_longlong(offset), id); 3921 3922 return E_NOTIMPL; 3923 } 3924 3925 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetCurrentProcessPeb(IDebugSystemObjects *iface, ULONG64 *offset) 3926 { 3927 FIXME("%p, %p stub.\n", iface, offset); 3928 3929 return E_NOTIMPL; 3930 } 3931 3932 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetProcessIdByPeb(IDebugSystemObjects *iface, ULONG64 offset, 3933 ULONG *id) 3934 { 3935 FIXME("%p, %s, %p stub.\n", iface, wine_dbgstr_longlong(offset), id); 3936 3937 return E_NOTIMPL; 3938 } 3939 3940 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetCurrentProcessSystemId(IDebugSystemObjects *iface, ULONG *sysid) 3941 { 3942 FIXME("%p, %p stub.\n", iface, sysid); 3943 3944 return E_NOTIMPL; 3945 } 3946 3947 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetProcessIdBySystemId(IDebugSystemObjects *iface, ULONG sysid, 3948 ULONG *id) 3949 { 3950 FIXME("%p, %u, %p stub.\n", iface, sysid, id); 3951 3952 return E_NOTIMPL; 3953 } 3954 3955 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetCurrentProcessHandle(IDebugSystemObjects *iface, 3956 ULONG64 *handle) 3957 { 3958 FIXME("%p, %p stub.\n", iface, handle); 3959 3960 return E_NOTIMPL; 3961 } 3962 3963 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetProcessIdByHandle(IDebugSystemObjects *iface, ULONG64 handle, 3964 ULONG *id) 3965 { 3966 FIXME("%p, %s, %p stub.\n", iface, wine_dbgstr_longlong(handle), id); 3967 3968 return E_NOTIMPL; 3969 } 3970 3971 static HRESULT STDMETHODCALLTYPE debugsystemobjects_GetCurrentProcessExecutableName(IDebugSystemObjects *iface, 3972 char *buffer, ULONG buffer_size, ULONG *exe_size) 3973 { 3974 FIXME("%p, %p, %u, %p stub.\n", iface, buffer, buffer_size, exe_size); 3975 3976 return E_NOTIMPL; 3977 } 3978 3979 static const IDebugSystemObjectsVtbl debugsystemobjectsvtbl = 3980 { 3981 debugsystemobjects_QueryInterface, 3982 debugsystemobjects_AddRef, 3983 debugsystemobjects_Release, 3984 debugsystemobjects_GetEventThread, 3985 debugsystemobjects_GetEventProcess, 3986 debugsystemobjects_GetCurrentThreadId, 3987 debugsystemobjects_SetCurrentThreadId, 3988 debugsystemobjects_SetCurrentProcessId, 3989 debugsystemobjects_GetNumberThreads, 3990 debugsystemobjects_GetTotalNumberThreads, 3991 debugsystemobjects_GetThreadIdsByIndex, 3992 debugsystemobjects_GetThreadIdByProcessor, 3993 debugsystemobjects_GetCurrentThreadDataOffset, 3994 debugsystemobjects_GetThreadIdByDataOffset, 3995 debugsystemobjects_GetCurrentThreadTeb, 3996 debugsystemobjects_GetThreadIdByTeb, 3997 debugsystemobjects_GetCurrentThreadSystemId, 3998 debugsystemobjects_GetThreadIdBySystemId, 3999 debugsystemobjects_GetCurrentThreadHandle, 4000 debugsystemobjects_GetThreadIdByHandle, 4001 debugsystemobjects_GetNumberProcesses, 4002 debugsystemobjects_GetProcessIdsByIndex, 4003 debugsystemobjects_GetCurrentProcessDataOffset, 4004 debugsystemobjects_GetProcessIdByDataOffset, 4005 debugsystemobjects_GetCurrentProcessPeb, 4006 debugsystemobjects_GetProcessIdByPeb, 4007 debugsystemobjects_GetCurrentProcessSystemId, 4008 debugsystemobjects_GetProcessIdBySystemId, 4009 debugsystemobjects_GetCurrentProcessHandle, 4010 debugsystemobjects_GetProcessIdByHandle, 4011 debugsystemobjects_GetCurrentProcessExecutableName, 4012 }; 4013 4014 /************************************************************ 4015 * DebugExtensionInitialize (DBGENG.@) 4016 * 4017 * Initializing Debug Engine 4018 * 4019 * PARAMS 4020 * pVersion [O] Receiving the version of extension 4021 * pFlags [O] Reserved 4022 * 4023 * RETURNS 4024 * Success: S_OK 4025 * Failure: Anything other than S_OK 4026 * 4027 * BUGS 4028 * Unimplemented 4029 */ 4030 HRESULT WINAPI DebugExtensionInitialize(ULONG * pVersion, ULONG * pFlags) 4031 { 4032 FIXME("(%p,%p): stub\n", pVersion, pFlags); 4033 4034 SetLastError(ERROR_CALL_NOT_IMPLEMENTED); 4035 4036 return E_NOTIMPL; 4037 } 4038 4039 /************************************************************ 4040 * DebugCreate (dbgeng.@) 4041 */ 4042 HRESULT WINAPI DebugCreate(REFIID riid, void **obj) 4043 { 4044 struct debug_client *debug_client; 4045 IUnknown *unk; 4046 HRESULT hr; 4047 4048 TRACE("%s, %p.\n", debugstr_guid(riid), obj); 4049 4050 debug_client = heap_alloc_zero(sizeof(*debug_client)); 4051 if (!debug_client) 4052 return E_OUTOFMEMORY; 4053 4054 debug_client->IDebugClient_iface.lpVtbl = &debugclientvtbl; 4055 debug_client->IDebugDataSpaces_iface.lpVtbl = &debugdataspacesvtbl; 4056 debug_client->IDebugSymbols3_iface.lpVtbl = &debugsymbolsvtbl; 4057 debug_client->IDebugControl2_iface.lpVtbl = &debugcontrolvtbl; 4058 debug_client->IDebugAdvanced_iface.lpVtbl = &debugadvancedvtbl; 4059 debug_client->IDebugSystemObjects_iface.lpVtbl = &debugsystemobjectsvtbl; 4060 debug_client->refcount = 1; 4061 list_init(&debug_client->targets); 4062 4063 unk = (IUnknown *)&debug_client->IDebugClient_iface; 4064 4065 hr = IUnknown_QueryInterface(unk, riid, obj); 4066 IUnknown_Release(unk); 4067 4068 return hr; 4069 } 4070 4071 /************************************************************ 4072 * DebugCreateEx (DBGENG.@) 4073 */ 4074 HRESULT WINAPI DebugCreateEx(REFIID riid, DWORD flags, void **obj) 4075 { 4076 FIXME("(%s, %#x, %p): stub\n", debugstr_guid(riid), flags, obj); 4077 4078 return E_NOTIMPL; 4079 } 4080 4081 /************************************************************ 4082 * DebugConnect (DBGENG.@) 4083 * 4084 * Creating Debug Engine client object and connecting it to remote host 4085 * 4086 * PARAMS 4087 * RemoteOptions [I] Options which define how debugger engine connects to remote host 4088 * InterfaceId [I] Interface Id of debugger client 4089 * pInterface [O] Pointer to interface as requested via InterfaceId 4090 * 4091 * RETURNS 4092 * Success: S_OK 4093 * Failure: Anything other than S_OK 4094 * 4095 * BUGS 4096 * Unimplemented 4097 */ 4098 HRESULT WINAPI DebugConnect(PCSTR RemoteOptions, REFIID InterfaceId, PVOID * pInterface) 4099 { 4100 FIXME("(%p,%p,%p): stub\n", RemoteOptions, InterfaceId, pInterface); 4101 4102 SetLastError(ERROR_CALL_NOT_IMPLEMENTED); 4103 4104 return E_NOTIMPL; 4105 } 4106