Package: libmpfr4
Version: 3.1.1-2
Severity: normal

A bug in mpfr_fits_u* functions on negative arguments for which the
rounding to an integer in the given rounding mode is 0 has been fixed
in the trunk and in the 3.1 branch, and Debian's version is still
affected. It is shown by the following program:

#include <stdio.h>
#include <mpfr.h>

int main (void)
{
  mpfr_t x;
  int err = 0;

  mpfr_init2 (x, 16);
  mpfr_set_si_2exp (x, -1, -2, MPFR_RNDN);  /* -1/4 */

  if (! mpfr_fits_ulong_p (x, MPFR_RNDN))
    {
      printf ("Error in mpfr_fits_ulong_p (-1/4, MPFR_RNDN).\n");
      err = 1;
    }

  if (! mpfr_fits_uint_p (x, MPFR_RNDN))
    {
      printf ("Error in mpfr_fits_uint_p (-1/4, MPFR_RNDN).\n");
      err = 1;
    }

  if (! mpfr_fits_ushort_p (x, MPFR_RNDN))
    {
      printf ("Error in mpfr_fits_ushort_p (-1/4, MPFR_RNDN).\n");
      err = 1;
    }

  mpfr_clear (x);
  return err;
}

The patch is on the GNU MPFR 3.1.2 page:

  http://www.mpfr.org/mpfr-3.1.2/

It could be a good idea to upgrade to 3.1.2 and apply the patches
before the freeze.

-- System Information:
Debian Release: jessie/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing'), (500, 'stable'), (1, 
'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.10-3-amd64 (SMP w/2 CPU cores)
Locale: LANG=POSIX, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages libmpfr4:amd64 depends on:
ii  libc6              2.17-93
ii  libgmp10           2:5.1.2+dfsg-3
ii  multiarch-support  2.17-93

libmpfr4:amd64 recommends no packages.

libmpfr4:amd64 suggests no packages.

-- no debconf information


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to