Tue, 01 Jun 2021 20:16:06 -0500
Fix a use after free that scanbuild detected
Testing Done:
Verified that scanbuild no longer detects the error.
Reviewed at https://reviews.imfreedom.org/r/701/
| libpurple/protocols/bonjour/mdns_common.c | file | annotate | diff | comparison | revisions |
--- a/libpurple/protocols/bonjour/mdns_common.c Tue Jun 01 20:15:16 2021 -0500 +++ b/libpurple/protocols/bonjour/mdns_common.c Tue Jun 01 20:16:06 2021 -0500 @@ -141,8 +141,8 @@ kvp = lst->data; g_free(kvp->key); g_free(kvp->value); + lst = g_slist_remove(lst, lst->data); g_free(kvp); - lst = g_slist_remove(lst, lst->data); } }