Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/sysmon Fix the KASSERT - we want to make sure that _...



details:   https://anonhg.NetBSD.org/src/rev/85e171caef39
branches:  trunk
changeset: 339041:85e171caef39
user:      pgoyette <pgoyette%NetBSD.org@localhost>
date:      Tue Jun 23 10:41:41 2015 +0000

description:
Fix the KASSERT - we want to make sure that _both_ pointers are non-NULL,
n ot just that one or the other is non-NULL!

diffstat:

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

diffs (27 lines):

diff -r 17eef8f5d770 -r 85e171caef39 sys/dev/sysmon/sysmon_envsys_events.c
--- a/sys/dev/sysmon/sysmon_envsys_events.c     Tue Jun 23 10:41:32 2015 +0000
+++ b/sys/dev/sysmon/sysmon_envsys_events.c     Tue Jun 23 10:41:41 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sysmon_envsys_events.c,v 1.115 2015/04/18 14:44:44 mlelstv Exp $ */
+/* $NetBSD: sysmon_envsys_events.c,v 1.116 2015/06/23 10:41:41 pgoyette Exp $ */
 
 /*-
  * Copyright (c) 2007, 2008 Juan Romero Pardines.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sysmon_envsys_events.c,v 1.115 2015/04/18 14:44:44 mlelstv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sysmon_envsys_events.c,v 1.116 2015/06/23 10:41:41 pgoyette Exp $");
 
 #include <sys/param.h>
 #include <sys/types.h>
@@ -768,7 +768,7 @@
        envsys_data_t *edata = see->see_edata;
 
        KASSERT(wk == &see->see_wk);
-       KASSERT(sme != NULL || edata != NULL);
+       KASSERT(sme != NULL && edata != NULL);
 
        mutex_enter(&sme->sme_mtx);
        see->see_flags |= SEE_EVENT_WORKING;



Home | Main Index | Thread Index | Old Index