From 280940516468141a1cc82687c417cfa42e48422e Mon Sep 17 00:00:00 2001 From: goldsimon Date: Thu, 6 Nov 2014 14:14:58 +0100 Subject: [PATCH] lwip_socket_init() is not needed any more -> compatibility define --- CHANGELOG | 4 ++++ src/api/sockets.c | 9 --------- src/core/init.c | 3 --- src/include/lwip/raw.h | 2 +- src/include/lwip/sockets.h | 2 +- src/include/netif/etharp.h | 2 +- 6 files changed, 7 insertions(+), 15 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index 3c53f000..9cedef2e 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -6,6 +6,10 @@ HISTORY ++ New features: + 2014-09-16: Simon Goldschmidt + * sockets.c/.h, init.c: lwip_socket_init() is not needed any more + -> compatibility define + 2014-09-16: Simon Goldschmidt * dns.c, opt.h: reduced ram usage by parsing DNS responses in place diff --git a/src/api/sockets.c b/src/api/sockets.c index e8fa417d..51a60f30 100644 --- a/src/api/sockets.c +++ b/src/api/sockets.c @@ -241,15 +241,6 @@ static void event_callback(struct netconn *conn, enum netconn_evt evt, u16_t len static void lwip_getsockopt_internal(void *arg); static void lwip_setsockopt_internal(void *arg); -/** - * Initialize this module. This function has to be called before any other - * functions in this module! - */ -void -lwip_socket_init(void) -{ -} - /** * Map a externally used socket index to the internal socket representation. * diff --git a/src/core/init.c b/src/core/init.c index 7d941d83..5c64b339 100644 --- a/src/core/init.c +++ b/src/core/init.c @@ -316,9 +316,6 @@ lwip_init(void) memp_init(); pbuf_init(); netif_init(); -#if LWIP_SOCKET - lwip_socket_init(); -#endif /* LWIP_SOCKET */ ip_init(); #if LWIP_ARP etharp_init(); diff --git a/src/include/lwip/raw.h b/src/include/lwip/raw.h index 350e29de..5dfb6af4 100644 --- a/src/include/lwip/raw.h +++ b/src/include/lwip/raw.h @@ -125,7 +125,7 @@ struct raw_pcb * raw_new_ip6 (u8_t proto); /* The following functions are the lower layer interface to RAW. */ u8_t raw_input (struct pbuf *p, struct netif *inp); -#define raw_init() /* Compatibility define, not init needed. */ +#define raw_init() /* Compatibility define, no init needed. */ #ifdef __cplusplus } diff --git a/src/include/lwip/sockets.h b/src/include/lwip/sockets.h index 3e1ca3a8..556f7021 100644 --- a/src/include/lwip/sockets.h +++ b/src/include/lwip/sockets.h @@ -398,7 +398,7 @@ struct timeval { }; #endif /* LWIP_TIMEVAL_PRIVATE */ -void lwip_socket_init(void); +#define lwip_socket_init() /* Compatibility define, no init needed. */ int lwip_accept(int s, struct sockaddr *addr, socklen_t *addrlen); int lwip_bind(int s, const struct sockaddr *name, socklen_t namelen); diff --git a/src/include/netif/etharp.h b/src/include/netif/etharp.h index 5dfa976b..ce008e71 100644 --- a/src/include/netif/etharp.h +++ b/src/include/netif/etharp.h @@ -185,7 +185,7 @@ struct etharp_q_entry { }; #endif /* ARP_QUEUEING */ -#define etharp_init() /* Compatibility define, not init needed. */ +#define etharp_init() /* Compatibility define, no init needed. */ void etharp_tmr(void); s8_t etharp_find_addr(struct netif *netif, ip_addr_t *ipaddr, struct eth_addr **eth_ret, ip_addr_t **ip_ret);