Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/sysmon Make this work the way the preceeding comment...



details:   https://anonhg.NetBSD.org/src/rev/04c0c085df57
branches:  trunk
changeset: 753409:04c0c085df57
user:      pgoyette <pgoyette%NetBSD.org@localhost>
date:      Fri Mar 26 21:06:25 2010 +0000

description:
Make this work the way the preceeding comment blocks says it works, and
break out of the while{ } when the callback returns false, not when it
returns true!

diffstat:

 sys/dev/sysmon/sysmon_envsys.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r 0435bf063560 -r 04c0c085df57 sys/dev/sysmon/sysmon_envsys.c
--- a/sys/dev/sysmon/sysmon_envsys.c    Fri Mar 26 20:52:00 2010 +0000
+++ b/sys/dev/sysmon/sysmon_envsys.c    Fri Mar 26 21:06:25 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: sysmon_envsys.c,v 1.100 2010/03/26 20:31:06 pgoyette Exp $     */
+/*     $NetBSD: sysmon_envsys.c,v 1.101 2010/03/26 21:06:25 pgoyette Exp $     */
 
 /*-
  * Copyright (c) 2007, 2008 Juan Romero Pardines.
@@ -64,7 +64,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sysmon_envsys.c,v 1.100 2010/03/26 20:31:06 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sysmon_envsys.c,v 1.101 2010/03/26 21:06:25 pgoyette Exp $");
 
 #include <sys/param.h>
 #include <sys/types.h>
@@ -2021,7 +2021,7 @@
 
                mutex_enter(&sme->sme_mtx);
                TAILQ_FOREACH(sensor, &sme->sme_sensors_list, sensors_head) {
-                       if ((*func)(sme, sensor, arg))
+                       if (!(*func)(sme, sensor, arg))
                                break;
                }
                mutex_exit(&sme->sme_mtx);



Home | Main Index | Thread Index | Old Index