winedbg: Use debuggee pointer size when extracting typed value.

Signed-off-by: Eric Pouech <eric.pouech@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Eric Pouech 2021-11-26 17:30:46 +01:00 committed by Alexandre Julliard
parent 16fb9640d7
commit c8006d07eb
2 changed files with 2 additions and 2 deletions

View File

@ -105,7 +105,8 @@ LONGLONG types_extract_as_longlong(const struct dbg_lvalue* lvalue,
if (issigned) *issigned = s;
break;
case SymTagPointerType:
if (!dbg_curr_process->be_cpu->fetch_integer(lvalue, sizeof(void*), s = FALSE, &rtn))
if (!types_get_info(&type, TI_GET_LENGTH, &size) ||
!dbg_curr_process->be_cpu->fetch_integer(lvalue, (unsigned)size, s = FALSE, &rtn))
RaiseException(DEBUG_STATUS_INTERNAL_ERROR, 0, 0, NULL);
break;
case SymTagArrayType:

View File

@ -44,7 +44,6 @@
* - type management:
* + some bits of internal types are missing (like type casts and the address
* operator)
* + most of the code implies that sizeof(void*) = sizeof(int)
* + all computations should be made on long long
* o expr computations are in int:s
* o bitfield size is on a 4-bytes