Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.sbin/apmd Zero clear the apm_power_info structure being ...
details: https://anonhg.NetBSD.org/src/rev/18e672b4eaf0
branches: trunk
changeset: 514968:18e672b4eaf0
user: enami <enami%NetBSD.org@localhost>
date: Sat Sep 15 02:42:26 2001 +0000
description:
Zero clear the apm_power_info structure being passed to ioctl.
diffstat:
usr.sbin/apmd/apmd.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diffs (17 lines):
diff -r 5075ec2c72b1 -r 18e672b4eaf0 usr.sbin/apmd/apmd.c
--- a/usr.sbin/apmd/apmd.c Sat Sep 15 01:32:10 2001 +0000
+++ b/usr.sbin/apmd/apmd.c Sat Sep 15 02:42:26 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: apmd.c,v 1.19 2001/04/06 11:13:47 wiz Exp $ */
+/* $NetBSD: apmd.c,v 1.20 2001/09/15 02:42:26 enami Exp $ */
/*-
* Copyright (c) 1996, 2000 The NetBSD Foundation, Inc.
@@ -106,6 +106,7 @@
int acon = 0;
int lowbattnow = 0;
+ memset(&bstate, 0, sizeof(bstate));
if (ioctl(fd, APM_IOC_GETPOWER, &bstate) == 0) {
/* various conditions under which we report status: something changed
enough since last report, or asked to force a print */
Home |
Main Index |
Thread Index |
Old Index