mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-31 22:25:38 -04:00
pipewire: module-zeroconf-discover: free correct pointer
Retrieve the pointer returned by `calloc()` and free that instead of freeing the pointer to a member. This has worked so far because as of yet `api` is the first member of the struct.
This commit is contained in:
parent
58e254ec63
commit
bbbf5724be
1 changed files with 3 additions and 1 deletions
|
|
@ -187,5 +187,7 @@ AvahiPoll* pw_avahi_poll_new(struct pw_loop *loop)
|
||||||
|
|
||||||
void pw_avahi_poll_free(AvahiPoll *p)
|
void pw_avahi_poll_free(AvahiPoll *p)
|
||||||
{
|
{
|
||||||
free(p);
|
struct impl *impl = SPA_CONTAINER_OF(p, struct impl, api);
|
||||||
|
|
||||||
|
free(impl);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue