winedbg: Rename print_longlong into print_sdecimal (to mimic print_hex).
Signed-off-by: Eric Pouech <eric.pouech@gmail.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
bbfbd7ac05
commit
0888943e72
|
@ -346,18 +346,9 @@ char* memory_offset_to_string(char *str, DWORD64 offset, unsigned mode)
|
||||||
return str;
|
return str;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void dbg_print_longlong(LONGLONG sv, BOOL is_signed)
|
static void dbg_print_sdecimal(dbg_lgint_t sv)
|
||||||
{
|
{
|
||||||
char tmp[24], *ptr = tmp + sizeof(tmp) - 1;
|
dbg_printf("%I64d", sv);
|
||||||
ULONGLONG uv, div;
|
|
||||||
*ptr = '\0';
|
|
||||||
if (is_signed && sv < 0) uv = -sv;
|
|
||||||
else { uv = sv; is_signed = FALSE; }
|
|
||||||
for (div = 10; uv; div *= 10, uv /= 10)
|
|
||||||
*--ptr = '0' + (uv % 10);
|
|
||||||
if (ptr == tmp + sizeof(tmp) - 1) *--ptr = '0';
|
|
||||||
if (is_signed) *--ptr = '-';
|
|
||||||
dbg_printf("%s", ptr);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void dbg_print_hex(DWORD size, dbg_lgint_t sv)
|
static void dbg_print_hex(DWORD size, dbg_lgint_t sv)
|
||||||
|
@ -512,7 +503,7 @@ static void print_typed_basic(const struct dbg_lvalue* lvalue)
|
||||||
fcp->Start += 256;
|
fcp->Start += 256;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!ok) dbg_print_longlong(val_int, TRUE);
|
if (!ok) dbg_print_sdecimal(val_int);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
@ -547,7 +538,7 @@ void print_basic(const struct dbg_lvalue* lvalue, char format)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
case 'd':
|
case 'd':
|
||||||
dbg_print_longlong(res, TRUE);
|
dbg_print_sdecimal(res);
|
||||||
return;
|
return;
|
||||||
|
|
||||||
case 'c':
|
case 'c':
|
||||||
|
@ -570,7 +561,7 @@ void print_basic(const struct dbg_lvalue* lvalue, char format)
|
||||||
}
|
}
|
||||||
if (lvalue->type.id == dbg_itype_segptr)
|
if (lvalue->type.id == dbg_itype_segptr)
|
||||||
{
|
{
|
||||||
dbg_print_longlong(types_extract_as_lgint(lvalue, NULL, NULL), TRUE);
|
dbg_print_sdecimal(types_extract_as_lgint(lvalue, NULL, NULL));
|
||||||
}
|
}
|
||||||
else print_typed_basic(lvalue);
|
else print_typed_basic(lvalue);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue