diff options
| author | 2008-11-10 05:19:48 +0000 | |
|---|---|---|
| committer | 2008-11-10 05:19:48 +0000 | |
| commit | a0148e891d61137a76326e01890d02b0a673b298 (patch) | |
| tree | 735a07e077c2cf821650bcd70bf368b9372fa8b7 | |
| parent | vm_map_lock() around calls to uvm_map_findspace(); ok tedu (diff) | |
| download | wireguard-openbsd-a0148e891d61137a76326e01890d02b0a673b298.tar.xz wireguard-openbsd-a0148e891d61137a76326e01890d02b0a673b298.zip | |
uninitialised value caused some lmenv(4) fans to never appear sometimes;
the bug was reported long time ago by Simon Slaytor with adm9240;
the eyes were cleared today by LLVM/Clang Static Analyser; ok deraadt
| -rw-r--r-- | sys/dev/i2c/lm87.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/i2c/lm87.c b/sys/dev/i2c/lm87.c index 1ecf04d2c7a..7a9389777cd 100644 --- a/sys/dev/i2c/lm87.c +++ b/sys/dev/i2c/lm87.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lm87.c,v 1.19 2007/06/24 05:34:35 dlg Exp $ */ +/* $OpenBSD: lm87.c,v 1.20 2008/11/10 05:19:48 cnst Exp $ */ /* * Copyright (c) 2005 Mark Kettenis @@ -141,7 +141,8 @@ lmenv_attach(struct device *parent, struct device *self, void *aux) printf(", cannot read Channel register\n"); return; } - } + } else + channel = 0; cmd = LM87_CONFIG1; if (iic_exec(sc->sc_tag, I2C_OP_READ_WITH_STOP, |
