From: Antoine Pitrou Date: Sun, 2 May 2010 19:51:14 +0000 (+0000) Subject: Issue #4687: Fix accuracy of garbage collection runtimes displayed with X-Git-Tag: v2.7b2~117 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=951919f558c1879ac6bba955977bb586c046c633;p=python Issue #4687: Fix accuracy of garbage collection runtimes displayed with gc.DEBUG_STATS. --- diff --git a/Misc/NEWS b/Misc/NEWS index c75f95c90b..18f0d3d44b 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -31,6 +31,9 @@ Core and Builtins Library ------- +- Issue #4687: Fix accuracy of garbage collection runtimes displayed with + gc.DEBUG_STATS. + - Issue #7192: webbrowser.get("firefox") now wors on Mac OS X, as does webbrowser.get("safari"). diff --git a/Modules/gcmodule.c b/Modules/gcmodule.c index 6c323edd72..fd339961e4 100644 --- a/Modules/gcmodule.c +++ b/Modules/gcmodule.c @@ -837,13 +837,13 @@ collect(int generation) } if (debug & DEBUG_STATS) { - t1 = get_time(); PySys_WriteStderr("gc: collecting generation %d...\n", generation); PySys_WriteStderr("gc: objects in each generation:"); for (i = 0; i < NUM_GENERATIONS; i++) PySys_WriteStderr(" %" PY_FORMAT_SIZE_T "d", gc_list_size(GEN_HEAD(i))); + t1 = get_time(); PySys_WriteStderr("\n"); }