decoder.c: In function ‘srd_decoder_unload_all’:
decoder.c:1080:27: warning: cast between incompatible function types from ‘int (*)(struct srd_decoder *)’ to ‘void (*)(void *, void *)’ [-Wcast-function-type]
g_slist_foreach(pd_list, (GFunc)srd_decoder_unload, NULL);
^
*/
SRD_API int srd_decoder_unload_all(void)
{
- g_slist_foreach(pd_list, (GFunc)srd_decoder_unload, NULL);
+ for (GSList *l = pd_list; l; l = l->next)
+ srd_decoder_unload(l->data);
g_slist_free(pd_list);
pd_list = NULL;