Skip to content

Commit c51cb89

Browse files
author
Jeff Brown
committed
Fix off-by-one.
Bug: 7330567 Change-Id: I8653435c77daefa24991595f68b9f23dd930f14a
1 parent a2f7ca7 commit c51cb89

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core/jni/android_os_UEventObserver.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ static bool isMatch(const char* buffer, size_t length) {
4949

5050
// Consider all zero-delimited fields of the buffer.
5151
const char* field = buffer;
52-
const char* end = buffer + length;
52+
const char* end = buffer + length + 1;
5353
do {
5454
if (strstr(field, match.string())) {
5555
ALOGV("Matched uevent message with pattern: %s", match.string());

0 commit comments

Comments
 (0)