Change in libosmocore[master]: ns2: Allow setting the socket priority for a UDP bind

pespin gerrit-no-reply at lists.osmocom.org
Thu Apr 29 17:59:26 UTC 2021


pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/23976 )

Change subject: ns2: Allow setting the socket priority for a UDP bind
......................................................................


Patch Set 2:

(1 comment)

https://gerrit.osmocom.org/c/libosmocore/+/23976/1/src/gb/gprs_ns2_udp.c 
File src/gb/gprs_ns2_udp.c:

https://gerrit.osmocom.org/c/libosmocore/+/23976/1/src/gb/gprs_ns2_udp.c@542 
PS1, Line 542: 		rc = osmo_sock_set_priority(priv->fd.fd, priority);
> well, then the caller is asking us to do something to a socket that doesn't exist yet. […]
I meant returning before calling setsockopt, since it's clear this function shouldn't call it if fd is -1

So throw a descriptive error and return an error, rather than getting a cryptical setsockopt error.



-- 
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/23976
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ifdfa086ce1c8d62b256abb3454b70cf53da9dcdb
Gerrit-Change-Number: 23976
Gerrit-PatchSet: 2
Gerrit-Owner: laforge <laforge at osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: pespin <pespin at sysmocom.de>
Gerrit-Comment-Date: Thu, 29 Apr 2021 17:59:26 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge at osmocom.org>
Comment-In-Reply-To: pespin <pespin at sysmocom.de>
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210429/59ad8407/attachment.htm>


More information about the gerrit-log mailing list