Skip to content

Commit 13d84b1

Browse files
jukkarnashif
authored andcommitted
tests: net: Add relevant Posix headers for networking
We need certain network related Posix header files so that the network tests using Posix symbols compiles ok. Previously the Posix symbols were introduced by network stack automatically, but that is no longer the case. Signed-off-by: Jukka Rissanen <[email protected]>
1 parent ac859d0 commit 13d84b1

File tree

2 files changed

+8
-0
lines changed
  • tests/net/socket

2 files changed

+8
-0
lines changed

tests/net/socket/tls_configurations/src/main.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,12 @@ LOG_MODULE_REGISTER(tls_configuration_sample, LOG_LEVEL_INF);
1010
#include <errno.h>
1111
#include <stdio.h>
1212

13+
#include <zephyr/posix/sys/eventfd.h>
14+
#include <zephyr/posix/poll.h>
15+
#include <zephyr/posix/arpa/inet.h>
16+
#include <zephyr/posix/unistd.h>
17+
#include <zephyr/posix/sys/socket.h>
18+
1319
#include <zephyr/net/socket.h>
1420
#include <zephyr/net/tls_credentials.h>
1521
#include <zephyr/net/net_if.h>

tests/net/socket/tls_ext/src/main.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99
#include <zephyr/net/net_ip.h>
1010
#include <zephyr/net/socket.h>
1111
#include <zephyr/net/tls_credentials.h>
12+
#include <zephyr/posix/sys/socket.h>
13+
#include <zephyr/posix/arpa/inet.h>
1214
#include <zephyr/posix/unistd.h>
1315
#include <zephyr/sys/util.h>
1416
#include <zephyr/ztest.h>

0 commit comments

Comments
 (0)