libei: implement a few missing functions

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
Peter Hutterer 2020-08-04 10:53:38 +10:00
parent 4f0637f726
commit b5f1082419

View file

@ -467,6 +467,16 @@ ei_get_event(struct ei *ei)
return ei_event_ref(e);
}
_public_ enum ei_event_type
ei_next_event_type(struct ei *ei)
{
if (list_empty(&ei->event_queue))
return EI_EVENT_NONE;
struct ei_event *e = list_first_entry(&ei->event_queue, e, link);
return e->type;
}
static struct message *
connection_parse_message(const char *data, size_t *len)
{