|
From: | address@hidden |
Subject: | Re: [lwip-users] static get_socket |
Date: | Mon, 5 Mar 2018 19:52:18 +0100 |
User-agent: | Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 |
On 05.03.2018 14:41, Mattia Settin wrote:
Dear All, I need to know the remote ip (remote_ip) of a speficif socket.Now i call the get_socket (removing the static attribute) and then point to the remote_ip:psock = get_socket(index); psock->conn->pcb.tcp->remote_ip.addr; The bad thing is that I need to modify the lwip library. anyone knows how to get the remote_ip give the socket or index ?
This is not an lwIP specific question. It's a socket API question. And the answer 'getpeername' is valid for (nearly?) all implementations of the socket API.
Simon
[Prev in Thread] | Current Thread | [Next in Thread] |