dump: fix memory_mapping_filter leak

Spotted by ASAN.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
This commit is contained in:
Marc-André Lureau 2017-05-04 02:38:46 +04:00 committed by Michael Tokarev
parent 543f8f13e2
commit 22c3aea8db
1 changed files with 1 additions and 0 deletions

View File

@ -337,6 +337,7 @@ void memory_mapping_filter(MemoryMappingList *list, int64_t begin,
if (cur->phys_addr >= begin + length ||
cur->phys_addr + cur->length <= begin) {
QTAILQ_REMOVE(&list->head, cur, next);
g_free(cur);
list->num--;
continue;
}