Re: [PATCH] set pkt_len when packet is received using L3 listening mode so that the ACK can be processed correctly

Marcel Holtmann <[email protected]>
Newsgroups dev.linux.lists.connman
Message-ID <[email protected]>
Hi John,

> The packet length is not set correctly when an IPv4 L3 ACK is received from a
> DHCP server.  This causes the packet to be rejected for having no
> MESSAGE_TYPE option and the lease is not renewed at the T1 point (or any
> subsequent retry).  Instead, the lease gets re-bound at the T2 point.
> 
> ---
> gdhcp/client.c | 1 +
> 1 file changed, 1 insertion(+)
> 
> diff --git a/gdhcp/client.c b/gdhcp/client.c
> index 82017692..c58c7be9 100644
> --- a/gdhcp/client.c
> +++ b/gdhcp/client.c
> @@ -2316,6 +2316,7 @@ static gboolean listener_event(GIOChannel *channel, GIOCondition condition,
> } else {
> re = dhcp_recv_l3_packet(&packet,
> dhcp_client->listener_sockfd);
> + pkt_len = (uint16_t)(unsigned int)re;
> xid = packet.xid;
> }
> } else if (dhcp_client->listen_mode == L_ARP) {

is this still needed? The patch does no longer apply.

Regards

Marcel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.