diff options
author | Petr Štetiar <ynezz@true.cz> | 2019-12-16 23:41:31 +0100 |
---|---|---|
committer | Petr Štetiar <ynezz@true.cz> | 2019-12-19 11:18:07 +0100 |
commit | c5f2053dfcfd1b81a3d29cdd27b26751b96e1acd (patch) | |
tree | 1b23bb10eb65bb090ca87e260e78353a0e0555b5 /ubusd_main.c | |
parent | 72be8e93f07d0dfb1f42edfbdb93ea04311dcb5a (diff) | |
download | ubus-c5f2053dfcfd1b81a3d29cdd27b26751b96e1acd.tar.gz |
workaround possibly false positive uses of memory after it is freed
scan-build from clang-9 has reported following:
libubox/list.h:83:22: warning: Use of memory after it is freed
entry->next->prev = entry->prev;
^~~~~~~~~~~
ubusd_event.c:42:3: warning: Use of memory after it is freed
ubusd_delete_event_source(ev);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Which might be a false positives, but in order to make the code pass the
static analyzer checks, rewrite the while loops on lists with the safe
list iterator.
Signed-off-by: Petr Štetiar <ynezz@true.cz>
Diffstat (limited to 'ubusd_main.c')
0 files changed, 0 insertions, 0 deletions