projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5fc04b3
)
Fix out-of-bounds table access
99/314199/1
accepted/tizen/unified/20240716.140303
accepted/tizen/unified/dev/20240722.073450
accepted/tizen/unified/toolchain/20240812.132537
accepted/tizen/unified/x/20240717.012443
accepted/tizen/unified/x/asan/20240813.230829
author
Michal Bloch
<m.bloch@samsung.com>
Mon, 8 Jul 2024 12:22:22 +0000
(14:22 +0200)
committer
Michal Bloch
<m.bloch@samsung.com>
Mon, 8 Jul 2024 12:22:22 +0000
(14:22 +0200)
Change-Id: I7603dfa64ae2a2a67613b0ff7f8b6d58daae4a1b
src/udev/udev-builtin-input_id.c
patch
|
blob
|
history
diff --git
a/src/udev/udev-builtin-input_id.c
b/src/udev/udev-builtin-input_id.c
index
840bd01
..
c27a2fe
100644
(file)
--- a/
src/udev/udev-builtin-input_id.c
+++ b/
src/udev/udev-builtin-input_id.c
@@
-113,7
+113,7
@@
static void get_cap_mask(sd_device *pdev, const char* attr,
log_device_debug(pdev, "%s decoded bit map:", attr);
val = bitmask_size / sizeof (unsigned long);
/* skip over leading zeros */
- while (
bitmask[val-1] == 0 && val >
0)
+ while (
val > 0 && bitmask[val-1] ==
0)
--val;
for (i = 0; i < val; ++i) {
DISABLE_WARNING_FORMAT_NONLITERAL;