dbghelp: Return proper size for local & parameters in SYMBOL_INFO.

This commit is contained in:
Eric Pouech 2005-12-19 18:20:47 +01:00 committed by Alexandre Julliard
parent d3805c307a
commit 750575ccf2
2 changed files with 5 additions and 2 deletions

View File

@ -142,7 +142,7 @@ struct symt_data
unsigned long address; /* DataIs{Global, FileStatic} */
struct
{
long offset; /* DataIs{Member,Local,Param} in bits*/
long offset; /* DataIs{Member,Local,Param} in bits */
unsigned long length; /* DataIs{Member} in bits */
unsigned long reg_id; /* DataIs{Local} (0 if frame relative) */
} s;

View File

@ -448,7 +448,10 @@ static void symt_fill_sym_info(const struct module* module,
if (!symt_get_info(sym, TI_GET_TYPE, &sym_info->TypeIndex))
sym_info->TypeIndex = 0;
sym_info->info = (DWORD)sym;
symt_get_info(sym, TI_GET_LENGTH, &size);
if (!symt_get_info(sym, TI_GET_LENGTH, &size) &&
sym_info->TypeIndex &&
!symt_get_info((struct symt*)sym_info->TypeIndex, TI_GET_LENGTH, &size))
size = 0;
sym_info->Size = (DWORD)size;
sym_info->ModBase = module->module.BaseOfImage;
sym_info->Flags = 0;