Attention is currently required from: msuraev. pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/28992 )
Change subject: Add osmo_sockaddr_strs_to_str() ......................................................................
Patch Set 6:
(4 comments)
Patchset:
PS6: It would be great if you explain where is this going to be used and the need for it.
File include/osmocom/core/sockaddr_str.h:
https://gerrit.osmocom.org/c/libosmocore/+/28992/comment/e28c28ce_7f0dc117 PS6, Line 63: #define OSMO_SOCKADDR_STR_FMT_ARGS(R) \ You could actually define these based on the ones below now. It actually makes more sense to swap the order of the 2 groups probably anyway.
File src/sockaddr_str.c:
https://gerrit.osmocom.org/c/libosmocore/+/28992/comment/518976a9_80b451ca PS6, Line 565: ret = snprintf(buf, rem, "("); FYI, you can have a look at using OSMO_STRBUF APIs, they are useful to implement stuff like done in this function.
https://gerrit.osmocom.org/c/libosmocore/+/28992/comment/020c9318_daf05360 PS6, Line 578: OSMO_SOCKADDR_STR_NO_PORT_FMT_ARGS(sa_str[i]), after); maybe add a boolean print_ports to decide whether to add ports or not?