diff --git a/net/igmp/igmp_group.c b/net/igmp/igmp_group.c index 1050a99e33..b84c085b8a 100644 --- a/net/igmp/igmp_group.c +++ b/net/igmp/igmp_group.c @@ -218,6 +218,10 @@ void igmp_grpfree(FAR struct net_driver_s *dev, wd_cancel(&group->wdog); + /* Cancel the workqueue */ + + work_cancel_sync(LPWORK, &group->work); + /* Remove the group structure from the group list in the device structure */ sq_rem((FAR sq_entry_t *)group, &dev->d_igmp_grplist);