PR jit/63854: Fix leak in real.c for i386:init_ext_80387_constants
authorDavid Malcolm <dmalcolm@redhat.com>
Mon, 1 Dec 2014 17:28:28 +0000 (17:28 +0000)
committerDavid Malcolm <dmalcolm@gcc.gnu.org>
Mon, 1 Dec 2014 17:28:28 +0000 (17:28 +0000)
gcc/ChangeLog:
PR jit/63854
* real.c (real_from_string): Add missing mpfr_clear.

From-SVN: r218233

gcc/ChangeLog
gcc/real.c

index 6063549cd2856a50d11e16a822eb96c3789163cd..c0248c29796df0fb445fe16e459f695189e0f8b1 100644 (file)
@@ -1,3 +1,8 @@
+2014-12-01  David Malcolm  <dmalcolm@redhat.com>
+
+       PR jit/63854
+       * real.c (real_from_string): Add missing mpfr_clear.
+
 2014-12-01  David Malcolm  <dmalcolm@redhat.com>
 
        PR jit/63854
index cebbe8d7a7ec99de7f99dad0ac16e11b1ee90e85..5e8050dbbb7d2c58043a1c7b6bc61b88e2a25fe5 100644 (file)
@@ -2067,6 +2067,7 @@ real_from_string (REAL_VALUE_TYPE *r, const char *str)
          gcc_assert (r->cl = rvc_normal);
          /* Set a sticky bit if mpfr_strtofr was inexact.  */
          r->sig[0] |= inexact;
+         mpfr_clear (m);
        }
     }