Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/hpc Don't read beyond the end of an array
details: https://anonhg.NetBSD.org/src/rev/b0b810ddcb71
branches: trunk
changeset: 347618:b0b810ddcb71
user: skrll <skrll%NetBSD.org@localhost>
date: Tue Sep 06 06:27:17 2016 +0000
description:
Don't read beyond the end of an array
diffstat:
sys/dev/hpc/btnmgr.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r 3a0afaf3c882 -r b0b810ddcb71 sys/dev/hpc/btnmgr.c
--- a/sys/dev/hpc/btnmgr.c Mon Sep 05 21:11:11 2016 +0000
+++ b/sys/dev/hpc/btnmgr.c Tue Sep 06 06:27:17 2016 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: btnmgr.c,v 1.28 2014/07/25 08:10:37 dholland Exp $ */
+/* $NetBSD: btnmgr.c,v 1.29 2016/09/06 06:27:17 skrll Exp $ */
/*-
* Copyright (c) 1999
@@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: btnmgr.c,v 1.28 2014/07/25 08:10:37 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: btnmgr.c,v 1.29 2016/09/06 06:27:17 skrll Exp $");
#ifdef _KERNEL_OPT
#include "opt_btnmgr.h"
@@ -205,7 +205,7 @@
/*
* install button event listener
*/
- for (id = 0; id <= n_button_config; id++)
+ for (id = 0; id < n_button_config; id++)
if (button_config[id].name != NULL)
sc->sc_hook_tag = config_hook(CONFIG_HOOK_BUTTONEVENT,
id, CONFIG_HOOK_SHARE,
Home |
Main Index |
Thread Index |
Old Index