1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

31 Commits

Author SHA1 Message Date
Robin
e9047063ca gnrc_sock_[udp|ip]: store return value before release
sock_[udp|ip]_recv returns `pkt->size` after pkt was released via `gnrc_pktbuf_release(pkt)`.
This can result in wrong values returned by this functions and thus is not according to its sepecification.

Storing this values before releasing pkt returning the stored values should fix this.
2018-11-12 14:58:26 +01:00
chrysn
f07308b07d gnrc: Extend gnrc_ipv6_get_header checks, use in sock recv
gnrc_sock_recv used to duplicate functionality of gnrc_ipv6_get_header,
but additionally checked whether the IPv6 snip is large enough.

All checks are now included in gnrc_ipv6_get_header, but as most of them
stem from programming / user errors, they were moved into asserts; this
constitutes an API change.
2018-09-28 19:40:59 +02:00
05b6af466c sys: add missig <string.h> includes 2018-09-20 23:47:40 +02:00
Martine Lenders
cb74063573 gnrc_sock_udp: use sock's local end-point for listening
Without this fix the listener doesn't actually listen on the
(potentially) ephemeral port introduced in #9382, but on port 0 which is
wrong.
2018-06-28 17:25:26 +02:00
Martine Lenders
a33399edf7 gnrc_sock_udp: provide fix for error state for full port pool 2018-06-20 14:51:18 +02:00
Martine Lenders
f8524cb4c0 gnrc_sock_udp: provide port for #9376 API fix 2018-06-20 14:51:17 +02:00
b343ff8ac9
Merge pull request #8470 from miri64/gnrc_sock/enh/set-remote-netif-implicitly
gnrc_sock: set remote network interface implicitly
2018-03-06 12:27:00 +01:00
Martine Lenders
15d405f597 gnrc_sock: add more cppcheck suppressions 2018-03-06 12:20:56 +01:00
Martine Lenders
98e45c3d55 gnrc_sock: set remote network interface implicitly
When there is only one interface we are simplifying a lot for the users
if the interface is set implicitly.
2018-03-05 17:01:36 +01:00
Martine Lenders
2621a57362 gnrc_sock: make sock compilable with gnrc_neterr
gnrc_sock currently does not compile with `gnrc_neterr` included, since
both `msg_try_receive()` and `msg_try_send()` expect a *pointer* to a
`msg_t`, not a `msg_t`.

To test, just compile an application using `gnrc_sock` (e.g.
`examples/gcoap`) with `USEMODULE+=gnrc_neterr`.
2018-02-17 13:53:38 +01:00
8a6d04ce52
Merge pull request #7925 from RIOT-OS/gnrc_netif2_integration/master
gnrc_netif2: gnrc_ipv6_nib: full integration into GNRC
2017-11-27 21:12:14 +01:00
Martine Lenders
71a7dbf918
gnrc: remove legacy network interface structures 2017-11-17 09:20:29 +01:00
c02ee081d9
Merge pull request #7174 from miri64/gnrc_sock/fix/return-EINVAL-for-inval-sock
sock: specify invalid parameter error
2017-11-02 17:30:35 +01:00
Lucas Jenss
6998ffbb14 cppcheck: Provide consistent reason formatting for all cppcheck-suppresses 2017-10-10 10:25:20 -07:00
Tobias Heider
3b5860451c gnrc/sock: fix fallthrough warning (#7403)
* gnrc/sock: fix fallthrough warning

* gnrc/sock: added spaces around "Fall Through."
2017-07-25 21:12:30 +02:00
Martine Lenders
ce0d81c5c8
sock: specify invalid parameter error 2017-06-12 13:54:55 +02:00
Martine Lenders
c2c2516a53 gnrc: fix cppcheck warnings 2017-04-14 14:36:14 +02:00
Oleg Hahm
d523c33015 doc: gnrc: fix doxygen and add missing doc 2017-03-10 14:56:28 +01:00
Oleg Hahm
7ee7801c10 *: remove trailing underscores from header guards 2017-01-19 18:30:53 +01:00
smlng
e28d14f77f gnrc, sock_udp: correct includes 2017-01-18 13:23:12 +01:00
smlng
a9cb29c46b gnrc_sock_udp: optimized remote ep handling 2017-01-18 13:23:12 +01:00
smlng
e2cf221a58 gnrc_sock_udp: get source port from dynmic port range
- get a new source port from a predefined range
    - check if port already in use, if required
    - refinded consistency checks for params of send()
2017-01-18 13:23:12 +01:00
smlng
2c5f07b62b gnrc_sock: add dynamic port range 2017-01-18 13:23:12 +01:00
Martine Lenders
50b1e7b6a5 gnrc_sock_udp: fix possibly dereferenced NULL pointer (#6203) 2016-12-13 09:03:57 +01:00
Martine Lenders
bd533dd785 gnrc_sock: move net/af.h include to sock_types.h 2016-11-18 12:33:01 +01:00
Martine Lenders
653e36277c gnrc_sock_ip: fix memcpy()/memset() sizeof-type
The type in the `sizeof()` is just plain wrong. This fixes it.
2016-11-09 21:24:28 +01:00
Martine Lenders
60d7b7efa2 gnrc_sock_udp: fixed minor bug 2016-10-30 18:48:41 +01:00
Martine Lenders
eb50b33fb5 gnrc_sock: actually **bind** implicitly 2016-10-29 20:58:27 +02:00
Martine Lenders
9508c8f5a5 tests: provide gnrc_sock_ip tests 2016-10-26 15:20:39 +02:00
Martine Lenders
1a6ebf2aae gnrc_sock_ip: provide port for sock_ip 2016-10-26 15:20:39 +02:00
Martine Lenders
b971c575ad gnrc_sock_udp: provide port for sock_udp 2016-10-26 15:20:38 +02:00