artulab
projects
/
openbsd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f5bb242
)
Initialize the stack local device id variable correctly.
author
anton
<anton@openbsd.org>
Thu, 11 Feb 2021 11:03:57 +0000
(11:03 +0000)
committer
anton
<anton@openbsd.org>
Thu, 11 Feb 2021 11:03:57 +0000
(11:03 +0000)
CID
1501705
sys/dev/usb/uhidpp.c
patch
|
blob
|
history
diff --git
a/sys/dev/usb/uhidpp.c
b/sys/dev/usb/uhidpp.c
index
5d4af1c
..
ca1c700
100644
(file)
--- a/
sys/dev/usb/uhidpp.c
+++ b/
sys/dev/usb/uhidpp.c
@@
-1,4
+1,4
@@
-/* $OpenBSD: uhidpp.c,v 1.
6 2021/02/11 07:26:03
anton Exp $ */
+/* $OpenBSD: uhidpp.c,v 1.
7 2021/02/11 11:03:57
anton Exp $ */
/*
* Copyright (c) 2021 Anton Lindqvist <anton@openbsd.org>
@@
-360,7
+360,7
@@
uhidpp_attach(struct device *parent, struct device *self, void *aux)
uint8_t serial[4];
struct uhidpp_device *dev = &sc->sc_devices[i];
const char *type;
- uint8_t device_id =
device_id
+ 1;
+ uint8_t device_id =
i
+ 1;
dev->d_id = device_id;