From 8dcd94b2cd01fed5fa0c1e6d56af1bba5389a866 Mon Sep 17 00:00:00 2001 From: Mark Salyzyn Date: Mon, 7 Nov 2016 13:54:42 -0800 Subject: [PATCH] liblog: logprint followup Add comment and braces to add maintenance clarity. Test: gTest logcat-unit-tests Bug: 35326290 Change-Id: Ie25b42faba19ae3cf52d4c6cefc4fc539ec23e79 --- liblog/logprint.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/liblog/logprint.c b/liblog/logprint.c index e61850dc4..af52528f8 100644 --- a/liblog/logprint.c +++ b/liblog/logprint.c @@ -625,14 +625,14 @@ static inline uint64_t get8LE(const uint8_t* src) } static bool findChar(const char** cp, size_t* len, int c) { - while (*len && isspace(**cp)) { - ++*cp; - --*len; + while ((*len) && isspace(*(*cp))) { + ++(*cp); + --(*len); } if (c == INT_MAX) return *len; - if (*len && (**cp == c)) { - ++*cp; - --*len; + if ((*len) && (*(*cp) == c)) { + ++(*cp); + --(*len); return true; } return false; @@ -991,7 +991,7 @@ no_room: LIBLOG_ABI_PUBLIC int android_log_processBinaryLogBuffer( struct logger_entry *buf, AndroidLogEntry *entry, - const EventTagMap *map __unused, + const EventTagMap *map __unused, // only on !__ANDROID__ char *messageBuf, int messageBufLen) { size_t inCount;