diff options
author | Jukka Rissanen <jukka.rissanen@linux.intel.com> | 2017-01-19 16:58:35 +0200 |
---|---|---|
committer | Jukka Rissanen <jukka.rissanen@linux.intel.com> | 2017-01-20 16:23:21 +0200 |
commit | 088289ec28ddc25e45ef179476057b72e140b0a5 (patch) | |
tree | c65beb84dd7ffec761df76971e69e405a6800990 /tests | |
parent | 724aa3ffbd8ddf29766b00e804941b7c718af8e0 (diff) |
net: context: Add status to connect callback
It is useful that the user API can know whether the connection
was established properly or not. So this commit adds status
parameter to connect callback in net_context API.
The call to connect callback needs to be set properly in TCP
code. This commit does not fix the connect callback call which
is not properly done right now in net_context.c.
Change-Id: I284a60ddd658ceef9e65022e96591f467a936a09
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/net/context/src/main.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/net/context/src/main.c b/tests/net/context/src/main.c index 76d2df3b8..560e9a287 100644 --- a/tests/net/context/src/main.c +++ b/tests/net/context/src/main.c @@ -349,7 +349,8 @@ static bool net_ctx_listen_v4(void) return true; } -static void connect_cb(struct net_context *context, void *user_data) +static void connect_cb(struct net_context *context, int status, + void *user_data) { sa_family_t family = POINTER_TO_INT(user_data); |