commit | 59f4caf4efcbd76478cdd2a1d800c0978144c5ba | [log] [tgz] |
---|---|---|
author | Neels Hofmeyr <neels@hofmeyr.de> | Thu Jul 19 22:13:19 2018 +0200 |
committer | Neels Hofmeyr <nhofmeyr@sysmocom.de> | Fri Jul 20 14:02:21 2018 +0000 |
tree | 626d8264eb9c36ebcca261c2d9ff7b99b4abbd8b | |
parent | 1504211fdcceb86bb76c19564e8b0b72a7cc2f6f [diff] [blame] |
add osmo_sockaddr_to_str_and_uint() This came from osmo-bsc refactoring patch I82e3f918295daa83274a4cf803f046979f284366 https://gerrit.osmocom.org/#/c/osmo-bsc/+/9671/6/src/osmo-bsc/gsm_data.c@1708 Add regression test in utils_test.c. Change-Id: I1f2918418c38918c5ac70acaa51a47adfca12b5e
diff --git a/include/osmocom/core/socket.h b/include/osmocom/core/socket.h index 47d9f30..20515b9 100644 --- a/include/osmocom/core/socket.h +++ b/include/osmocom/core/socket.h
@@ -44,6 +44,9 @@ int osmo_sockaddr_is_local(struct sockaddr *addr, unsigned int addrlen); +unsigned int osmo_sockaddr_to_str_and_uint(char *addr, unsigned int addr_len, uint16_t *port, + const struct sockaddr *sa); + int osmo_sock_unix_init(uint16_t type, uint8_t proto, const char *socket_path, unsigned int flags);