Suppress false-positive static analyzer warnings
by hinting the analyzer with assertions. Test: built without seeing warnings. Change-Id: I0d43d4ceafd7f68be89cad6c930c85ee7b6d5165
This commit is contained in:
parent
2c3a2a8c5c
commit
249bd05038
2 changed files with 2 additions and 0 deletions
|
@ -222,6 +222,7 @@ static int LogBufferLog(struct LogBuffer* log,
|
|||
log->last[logId] = node->prev;
|
||||
}
|
||||
list_remove(node);
|
||||
LOG_ALWAYS_FATAL_IF(node == log->last[logId], "corrupted list");
|
||||
free(e);
|
||||
}
|
||||
/* add entry to list */
|
||||
|
|
|
@ -250,6 +250,7 @@ LIBLOG_ABI_PUBLIC void android_log_format_free(AndroidLogFormat* p_format) {
|
|||
while (!list_empty(&convertHead)) {
|
||||
struct listnode* node = list_head(&convertHead);
|
||||
list_remove(node);
|
||||
LOG_ALWAYS_FATAL_IF(node == list_head(&convertHead), "corrupted list");
|
||||
free(node);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue