From 9a77dcc71f438616913f910d739f0c316c1a18a9 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Mon, 19 Mar 2012 20:42:03 +0000 Subject: [PATCH] - wrapper: fix bug that reported wildly wrong CPU time svn path=/trunk/boinc/; revision=25457 --- checkin_notes | 6 ++++++ lib/procinfo.cpp | 1 + 2 files changed, 7 insertions(+) diff --git a/checkin_notes b/checkin_notes index 5195ff25a0..cae8b7e6e3 100644 --- a/checkin_notes +++ b/checkin_notes @@ -2793,3 +2793,9 @@ David 19 Mar 2011 lib/ procinfo.cpp + +David 19 Mar 2011 + - wrapper: fix bug that reported wildly wrong CPU time + + lib/ + procinfo.cpp diff --git a/lib/procinfo.cpp b/lib/procinfo.cpp index c40cdf647c..ff1e9a02f7 100644 --- a/lib/procinfo.cpp +++ b/lib/procinfo.cpp @@ -154,6 +154,7 @@ double process_tree_cpu_time(int pid) { retval = procinfo_setup(pm); if (retval) return 0; + pi.clear(); pi.id = pid; procinfo_app(pi, NULL, pm, NULL); return pi.user_time + pi.kernel_time;