diff options
-rwxr-xr-x | ChangeLog | 6 | ||||
-rw-r--r-- | builtin.c | 4 | ||||
-rw-r--r-- | mpfr.c | 4 |
3 files changed, 12 insertions, 2 deletions
@@ -1,3 +1,9 @@ +2019-01-14 Arnold D. Robbins <arnold@skeeve.com> + + * builtin.c (do_intdiv): Add unref of subscripts. + * mpfr.c (do_mpfr_intdiv): Ditto. + Thanks to Andy Schorr for noticing. + 2019-01-09 John E. Malmberg <wb8tyw@qsl.net> * awk.h: For non GCC, have __attribute__ definition match @@ -3,7 +3,7 @@ */ /* - * Copyright (C) 1986, 1988, 1989, 1991-2018 the Free Software Foundation, Inc. + * Copyright (C) 1986, 1988, 1989, 1991-2019 the Free Software Foundation, Inc. * * This file is part of GAWK, the GNU implementation of the * AWK Programming Language. @@ -4048,11 +4048,13 @@ do_intdiv(int nargs) lhs = assoc_lookup(result, sub); unref(*lhs); *lhs = make_number((AWKNUM) quotient); + unref(sub); sub = make_string("remainder", 9); lhs = assoc_lookup(result, sub); unref(*lhs); *lhs = make_number((AWKNUM) remainder); + unref(sub); DEREF(denominator); DEREF(numerator); @@ -3,7 +3,7 @@ */ /* - * Copyright (C) 2012, 2013, 2015, 2017, 2018, + * Copyright (C) 2012, 2013, 2015, 2017, 2018, 2019, * the Free Software Foundation, Inc. * * This file is part of GAWK, the GNU implementation of the @@ -1265,11 +1265,13 @@ do_mpfr_intdiv(int nargs) lhs = assoc_lookup(result, sub); unref(*lhs); *lhs = quotient; + unref(sub); sub = make_string("remainder", 9); lhs = assoc_lookup(result, sub); unref(*lhs); *lhs = remainder; + unref(sub); return make_number((AWKNUM) 0.0); } |