Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1909)

Unified Diff: content/renderer/render_thread_impl.cc

Issue 8773018: Initialize the CPU usage variable. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merged Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tools/valgrind/memcheck/suppressions.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_thread_impl.cc
diff --git a/content/renderer/render_thread_impl.cc b/content/renderer/render_thread_impl.cc
index 7fdb883a31dafaddd8e325a6200ce24dc30e6226..a4dac21d12ff7f5f08668321845b2ef9d5c75a1d 100644
--- a/content/renderer/render_thread_impl.cc
+++ b/content/renderer/render_thread_impl.cc
@@ -621,7 +621,7 @@ void RenderThreadImpl::IdleHandlerInForegroundTab() {
if (idle_notifications_to_skip_ > 0) {
idle_notifications_to_skip_--;
} else {
- int cpu_usage;
+ int cpu_usage = 0;
Send(new ViewHostMsg_GetCPUUsage(&cpu_usage));
if (cpu_usage < kIdleCPUUsageThresholdInPercents &&
v8::V8::IdleNotification()) {
« no previous file with comments | « no previous file | tools/valgrind/memcheck/suppressions.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698