From 1435d613ee632bd7a2aa15180acf06ff3723da41 Mon Sep 17 00:00:00 2001
From: Martin Jansa <martin.jansa@gmail.com>
Date: Sat, 26 Apr 2025 13:03:35 +0200
Subject: [PATCH] Fix implicit-declaration error

* taken from:
  https://github.com/sbwml/package_network_utils_linux-atm/blob/main/patches/900-fix-implicit-declaration-error.patch

* fixes:
  http://errors.yoctoproject.org/Errors/Details/766901/
  linux-atm-2.5.2/src/led/conn.c:414:57: error: passing argument 3 of 'accept' from incompatible pointer type [-Wincompatible-pointer-types]

Upstream-Status: Inappropriate [Upstream is dead]
Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
---
 src/led/conn.c     | 2 +-
 src/maint/hediag.c | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/led/conn.c b/src/led/conn.c
index 99da5e4..89639e1 100644
--- a/src/led/conn.c
+++ b/src/led/conn.c
@@ -405,7 +405,7 @@ Conn_t *accept_conn(Conn_t *conn)
 {
         Conn_t *new;
         struct sockaddr_atmsvc addr;
-        size_t len;
+        socklen_t len;
         int fd;
         char buff[MAX_ATM_ADDR_LEN+1];
 
diff --git a/src/maint/hediag.c b/src/maint/hediag.c
index a4f792f..3b1b7fb 100644
--- a/src/maint/hediag.c
+++ b/src/maint/hediag.c
@@ -9,6 +9,7 @@
 #include <linux/atmdev.h>
 #include <linux/sonet.h>
 #include <linux/atm_he.h>
+#include <string.h>
 
 struct reg_table {
 	unsigned addr;
