On Mon, Mar 22, 2021 at 07:49:19PM +0800, 黎醒聪 wrote: > Use dig to reproduce this bug, it will TCP timeout. > > dig example.com +tcp > > It should be introduced in commit 51f7bc924cbcdeb09cbb83249b70c121d1ffa31e > > I try to fix this typo and the TCP query works as usual: > > Change tcp_request() in forward.c: > > Wrong: > server_send(last_server, last_server->tcpfd, packet, m + sizeof(u16), > MSG_FASTOPEN); > > Correct: > server_send(last_server, last_server->tcpfd, packet, size + sizeof(u16), > MSG_FASTOPEN);
--- a/src/forward.c +++ b/src/forward.c @@ -2003,7 +2003,7 @@ unsigned char *tcp_request(int confd, time_t now, } #ifdef MSG_FASTOPEN - server_send(last_server, last_server->tcpfd, packet, m + sizeof(u16), MSG_FASTOPEN); + server_send(last_server, last_server->tcpfd, packet, size + sizeof(u16), MSG_FASTOPEN); if (errno == 0) data_sent = 1; > Go on and fix, thanks! You are missing the opportunity for contributing a patch to a libre software project. > Xingcong Li Groeten Geert Stappers -- Silence is hard to parse _______________________________________________ Dnsmasq-discuss mailing list Dnsmasq-discuss@lists.thekelleys.org.uk https://lists.thekelleys.org.uk/cgi-bin/mailman/listinfo/dnsmasq-discuss