diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2021-03-16 21:08:07 +0000 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2021-03-16 21:08:07 +0000 |
commit | 0693602a23276b076a679b1e7ed9125a444336b6 (patch) | |
tree | 92abe05dedd247630a82e526bd28098873929736 /tests | |
parent | 5b7f5586d182b0cafb1f8d558992a14763e2953e (diff) | |
parent | 7625a1ed013a042748753750c9d9b1a33c9cd8e0 (diff) |
Merge remote-tracking branch 'remotes/rth-gitlab/tags/pull-misc-20210315' into staging
Fix qemu_strtosz testsuite failures for i686.
# gpg: Signature made Mon 15 Mar 2021 18:49:12 GMT
# gpg: using RSA key 7A481E78868B4DB6A85A05C064DF38E8AF7E215F
# gpg: issuer "richard.henderson@linaro.org"
# gpg: Good signature from "Richard Henderson <richard.henderson@linaro.org>" [full]
# Primary key fingerprint: 7A48 1E78 868B 4DB6 A85A 05C0 64DF 38E8 AF7E 215F
* remotes/rth-gitlab/tags/pull-misc-20210315:
utils: Use fixed-point arithmetic in qemu_strtosz
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/unit/test-cutils.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/unit/test-cutils.c b/tests/unit/test-cutils.c index bad3a60993..e025b54c05 100644 --- a/tests/unit/test-cutils.c +++ b/tests/unit/test-cutils.c @@ -2128,7 +2128,7 @@ static void test_qemu_strtosz_float(void) str = "12.345M"; err = qemu_strtosz(str, &endptr, &res); g_assert_cmpint(err, ==, 0); - g_assert_cmpint(res, ==, (uint64_t) (12.345 * MiB)); + g_assert_cmpint(res, ==, (uint64_t) (12.345 * MiB + 0.5)); g_assert(endptr == str + 7); } |