[riot-notifications] [RIOT-OS/RIOT] posix_sockets.c: fix send() for connected UDP sockets (#11364)

Martine Lenders notifications at github.com
Wed Apr 10 12:28:54 CEST 2019


miri64 commented on this pull request.



> @@ -959,7 +959,13 @@ static ssize_t socket_sendto(socket_t *s, const void *buffer, size_t length,
 #endif
 #ifdef MODULE_SOCK_UDP
         case SOCK_DGRAM:
-            if ((res = sock_udp_send(&s->sock->udp, buffer, length, &ep)) < 0) {
+            if (address == NULL) {
+                res = sock_udp_get_remote((sock_udp_t *)s->sock, &ep);

> The cast is now fixed.

It's hard to track your changes during the review if you force-push (especially if it involves a rebase). So please only force-push (after squashing your commits appropriately), when the review is finished and the PR is approved.

> I did not see a point in supporting connected raw sockets so far. Where would you like the wrapper function to live?

Then let's move this as suggested to a follow-up.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/11364#discussion_r273891199
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190410/142fee0b/attachment.html>


More information about the notifications mailing list