From 410367e6851e8fb386abecb88369d6fa4e9871b9 Mon Sep 17 00:00:00 2001 From: Denys Fedoryshchenko Date: Tue, 9 Apr 2024 23:40:48 +0300 Subject: musl: Add musl compatibility Thanks for hints Alpine Linux project and their patches: https://git.alpinelinux.org/aports/tree/community/accel-ppp?h=master We can adjust a bit code and cmake config files to make accel-ppp buildable under musl "as is". Signed-off-by: Denys Fedoryshchenko --- accel-pppd/ctrl/l2tp/l2tp.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'accel-pppd/ctrl/l2tp') diff --git a/accel-pppd/ctrl/l2tp/l2tp.c b/accel-pppd/ctrl/l2tp/l2tp.c index 027d710..9fc2283 100644 --- a/accel-pppd/ctrl/l2tp/l2tp.c +++ b/accel-pppd/ctrl/l2tp/l2tp.c @@ -853,7 +853,11 @@ static void l2tp_tunnel_free_sessions(struct l2tp_conn_t *conn) void *sessions = conn->sessions; conn->sessions = NULL; +#ifdef HAVE_FREE_FN_T tdestroy(sessions, (__free_fn_t)l2tp_session_free); +#else + tdestroy(sessions, free); +#endif /* Let l2tp_session_free() handle the session counter and * the reference held by the tunnel. */ -- cgit v1.2.3