From f6916dbed4233ef0e202d1b299cb5a2e9287a696 Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Tue, 6 Apr 2010 17:43:29 +0200 Subject: telnetd: fill hostname field in utmp/wtmp records function old new delta get_lsa - 109 +109 make_new_session 438 504 +66 get_peer_lsa - 10 +10 ftpd_main 2340 2267 -73 get_sock_lsa 101 10 -91 ------------------------------------------------------------------------------ (add/remove: 2/0 grow/shrink: 1/2 up/down: 185/-164) Total: 21 bytes Signed-off-by: Denys Vlasenko --- include/libbb.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include') diff --git a/include/libbb.h b/include/libbb.h index f3121eb47..357571fd8 100644 --- a/include/libbb.h +++ b/include/libbb.h @@ -530,6 +530,8 @@ int create_and_connect_stream_or_die(const char *peer, int port) FAST_FUNC; int xconnect_stream(const len_and_sockaddr *lsa) FAST_FUNC; /* Get local address of bound or accepted socket */ len_and_sockaddr *get_sock_lsa(int fd) FAST_FUNC RETURNS_MALLOC; +/* Get remote address of connected or accepted socket */ +len_and_sockaddr *get_peer_lsa(int fd) FAST_FUNC RETURNS_MALLOC; /* Return malloc'ed len_and_sockaddr with socket address of host:port * Currently will return IPv4 or IPv6 sockaddrs only * (depending on host), but in theory nothing prevents e.g. -- cgit v1.2.3