blob: b2549aff4190a978c1976f473e82781b1dc8d73f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
#include "util.h"
#include <glib.h>
gpointer
cmumble_find_by_id(GList *list, gsize member_offset, guint id)
{
gpointer el = NULL;
GList *l;
for (l = list; l; l = l->next) {
if (G_STRUCT_MEMBER(uint32_t, l->data, member_offset) == id) {
el = l->data;
break;
}
}
return el;
}
|