1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-09 00:00:04 +01:00

glibc: support older versions

Ubuntu Xenial's version lacks this helper define, add it if missing
so it can build
This commit is contained in:
Andy Green 2020-03-21 15:20:41 +00:00
parent 2a7a92f4d5
commit f684daefda

View file

@ -26,6 +26,10 @@
#include <glib-unix.h>
#if !defined(G_SOURCE_FUNC)
#define G_SOURCE_FUNC(f) ((GSourceFunc) (void (*)(void)) (f))
#endif
#define wsi_to_subclass(_w) ((_w)->w_read.glib.source)
#define wsi_to_gsource(_w) ((GSource *)wsi_to_subclass(_w))
#define pt_to_loop(_pt) ((_pt)->glib.loop)