mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-08 18:23:57 -06:00
util: remove support for hex numbers with a scaling suffix
This was deprecated in 6.0 and can now be removed. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
eaaaf8abdc
commit
8b902e3d23
4 changed files with 19 additions and 19 deletions
|
@ -2315,6 +2315,14 @@ static void test_qemu_strtosz_invalid(void)
|
|||
g_assert_cmpint(res, ==, 0xbaadf00d);
|
||||
g_assert(endptr == str);
|
||||
|
||||
/* No suffixes */
|
||||
str = "0x18M";
|
||||
endptr = NULL;
|
||||
err = qemu_strtosz(str, &endptr, &res);
|
||||
g_assert_cmpint(err, ==, -EINVAL);
|
||||
g_assert_cmpint(res, ==, 0xbaadf00d);
|
||||
g_assert(endptr == str);
|
||||
|
||||
/* No negative values */
|
||||
str = "-0";
|
||||
endptr = NULL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue