diff --git a/src/modules/Gmp/mpf.cmod b/src/modules/Gmp/mpf.cmod index 130ebd5c1e79004c2754aea176b1e01cb6ea45f5..2210258df6e979028b4545f596468c961618bdc7 100644 --- a/src/modules/Gmp/mpf.cmod +++ b/src/modules/Gmp/mpf.cmod @@ -2,7 +2,7 @@ || This file is part of Pike. For copyright information see COPYRIGHT. || Pike is distributed under GPL, LGPL and MPL. See the file COPYING || for more information. -|| $Id: mpf.cmod,v 1.37 2008/05/29 21:58:44 mast Exp $ +|| $Id: mpf.cmod,v 1.38 2008/06/23 16:41:03 mast Exp $ */ #include "global.h" @@ -903,7 +903,7 @@ PIKECLASS mpf GC_RECURSE { - if (mc_count_bytes (THIS)) + if (mc_count_bytes (Pike_fp->current_object)) /* FIXME: Should count the allocated size. */ mc_counted_bytes += (mpf_get_prec (THISMPF) + 7) / 8 + sizeof (mpf_t); } diff --git a/src/modules/Gmp/mpq.cmod b/src/modules/Gmp/mpq.cmod index a4db13e00f604299a91d37be7f50e753114706e8..ed58b4bb891428f66ede86f10166839789e3f9d5 100644 --- a/src/modules/Gmp/mpq.cmod +++ b/src/modules/Gmp/mpq.cmod @@ -2,7 +2,7 @@ || This file is part of Pike. For copyright information see COPYRIGHT. || Pike is distributed under GPL, LGPL and MPL. See the file COPYING || for more information. -|| $Id: mpq.cmod,v 1.29 2008/05/29 21:58:44 mast Exp $ +|| $Id: mpq.cmod,v 1.30 2008/06/23 16:41:03 mast Exp $ */ #include "global.h" @@ -941,7 +941,7 @@ PIKECLASS mpq GC_RECURSE { - if (mc_count_bytes (THIS)) + if (mc_count_bytes (Pike_fp->current_object)) mc_counted_bytes += #ifdef MPZ_T_HAS__MP_ALLOC mpq_numref (THISMPQ)[0]._mp_alloc * sizeof (mp_limb_t) + diff --git a/src/program.c b/src/program.c index 7946924bfae8813756563a8cf94477b418f89d93..61bbf3ded0c64ef456f130658d83eb112a4a523d 100644 --- a/src/program.c +++ b/src/program.c @@ -2,7 +2,7 @@ || This file is part of Pike. For copyright information see COPYRIGHT. || Pike is distributed under GPL, LGPL and MPL. See the file COPYING || for more information. -|| $Id: program.c,v 1.719 2008/06/10 13:56:51 grubba Exp $ +|| $Id: program.c,v 1.720 2008/06/23 16:41:02 mast Exp $ */ #include "global.h" @@ -3770,7 +3770,7 @@ PMOD_EXPORT void set_exit_callback(void (*exit)(struct object *)) * the C level then you should add something like this to the recurse * callback so that Pike.count_memory remains accurate: * - * if (mc_count_bytes (Pike_fp->current_storage)) + * if (mc_count_bytes (Pike_fp->current_object)) * mc_counted_bytes += <size of the allocated memory block(s)> * * If the allocated memory is shared between objects then it gets more