diff options
| author | NIIBE Yutaka <[email protected]> | 2026-07-30 01:48:32 +0200 |
|---|---|---|
| committer | NIIBE Yutaka <[email protected]> | 2026-07-30 01:48:32 +0200 |
| commit | 9cc750a816554e46d3e1496533f927b17ef3fcef (patch) | |
| tree | 639e8eb17f204e59f76c88e41ea8c8eb4ff3cb1f /tests | |
| parent | doc: some comment updates (diff) | |
| download | libgpg-error-9cc750a816554e46d3e1496533f927b17ef3fcef.tar.gz libgpg-error-9cc750a816554e46d3e1496533f927b17ef3fcef.zip | |
tests: Fix gpgrt_bsprintf test for PowerPC 64.
* tests/t-printf.c (check_large_float): Skip the test when
it's IBM double-double.
--
Reported-by: C. Neidahl
Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/t-printf.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/t-printf.c b/tests/t-printf.c index b0a3f3f..fb8bdc3 100644 --- a/tests/t-printf.c +++ b/tests/t-printf.c @@ -469,12 +469,15 @@ check_large_float (void) show ("format \"%%.100Lf\" with DBL_MAX: ->%s<-\n", buf); gpgrt_free (buf); -# ifdef HAVE_LONG_DOUBLE_WIDER +# if defined(__powerpc64__) && LDBL_MANT_DIG == 106 + if (verbose) + show ("IBM double-double - skipping LDBL_MAX test\n"); +# elif defined(HAVE_LONG_DOUBLE_WIDER) ld = LDBL_MAX; buf = gpgrt_bsprintf ("%.100Lf\n", ld); if (buf) { - fail ("format \"%%.100Lf\" with LDBL_MAX unexpectly did not fail\n"); + fail ("format \"%%.100Lf\" with LDBL_MAX unexpectedly did not fail\n"); } else if (verbose) show ("format \"%%.100Lf\" with LDBL_MAX failed as expected\n"); |
