monit-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[monit-dev] [monit] r369 committed - cleanup and add debug info for erro


From: monit
Subject: [monit-dev] [monit] r369 committed - cleanup and add debug info for errors
Date: Thu, 14 Apr 2011 06:10:34 +0000

Revision: 369
Author:   address@hidden
Date:     Wed Apr 13 23:06:55 2011
Log:      cleanup and add debug info for errors
http://code.google.com/p/monit/source/detail?r=369

Modified:
 /trunk/process/sysdep_SOLARIS.c

=======================================
--- /trunk/process/sysdep_SOLARIS.c     Wed Apr 13 23:06:16 2011
+++ /trunk/process/sysdep_SOLARIS.c     Wed Apr 13 23:06:55 2011
@@ -376,7 +376,7 @@

   if (old_total == 0) {
si->total_cpu_user_percent = si->total_cpu_syst_percent = si->total_cpu_wait_percent = -10;
-  } else if ((diff_total = total - old_total)) {
+  } else if ((diff_total = total - old_total) > 0) {
si->total_cpu_user_percent = (int)((1000 * (cpu_user - old_cpu_user)) / diff_total); si->total_cpu_syst_percent = (int)((1000 * (cpu_syst - old_cpu_syst)) / diff_total); si->total_cpu_wait_percent = (int)((1000 * (cpu_wait - old_cpu_wait)) / diff_total);



reply via email to

[Prev in Thread] Current Thread [Next in Thread]