include: net: socketutils: Allow to build for CONFIG_POSIX_API
Previously, they were tested only with CONFIG_NET_SOCKETS_POSIX_NAMES, but should also work with POSIX subsys. Achieve this by including POSIX headers in this case. Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
This commit is contained in:
parent
25b0c04b5d
commit
7c49ac6e0a
2 changed files with 8 additions and 5 deletions
|
@ -4,6 +4,12 @@
|
|||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
#ifdef CONFIG_NET_SOCKETS_POSIX_NAMES
|
||||
#include <net/socket.h>
|
||||
#else
|
||||
#include <posix/netdb.h>
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @brief Find port in addr:port string.
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue