udp: Remove the unnessary check of addr size in udp_readahead
@@ -257,15 +257,6 @@ static inline void udp_readahead(struct udp_recvfrom_s *pstate)
}
#endif
- if (0
-#ifdef CONFIG_NET_IPv6
- || src_addr_size == sizeof(struct sockaddr_in6)
-#endif
-#ifdef CONFIG_NET_IPv4
- || src_addr_size == sizeof(struct sockaddr_in)
-#endif
- )
- {
if (pstate->ir_msg->msg_name)
{
pstate->ir_msg->msg_namelen =
@@ -275,7 +266,6 @@ static inline void udp_readahead(struct udp_recvfrom_s *pstate)
memcpy(pstate->ir_msg->msg_name, srcaddr,
pstate->ir_msg->msg_namelen);
}
- }
if (pstate->ir_msg->msg_iov->iov_len > 0)
{
