1
0
Fork 0

Fix a regression caused by #2571

Strings inside modules would not be listed, now it outputs module."string" instead.

Closes #3003
This commit is contained in:
Duncan Ogilvie 2023-01-18 11:10:30 +01:00
parent d7e68c7056
commit f35c8a54a4
1 changed files with 14 additions and 1 deletions

View File

@ -115,9 +115,22 @@ bool stackcommentget(duint addr, STACK_COMMENT* comment)
if(*module) //module
{
if(*label) //+label
{
sprintf_s(comment->comment, "%s.%s", module, label);
}
else //module only
sprintf_s(comment->comment, "%s.%p", module, data);
{
//prefer strings over just module.address
char string[MAX_STRING_SIZE] = "";
if(DbgGetStringAt(data, string))
{
_snprintf_s(comment->comment, _TRUNCATE, "%s.%s", module, string);
}
else
{
_snprintf_s(comment->comment, _TRUNCATE, "%s.%p", module, data);
}
}
return true;
}
else if(*label) //label only