From 403068740061b6e9ddd16f5f3d2f2db719b361b6 Mon Sep 17 00:00:00 2001 From: robot Date: Wed, 20 Dec 2023 13:07:38 +0800 Subject: [PATCH] =?UTF-8?q?=E5=9C=A8=E8=BF=9B=E8=A1=8Chttps=E6=8F=A1?= =?UTF-8?q?=E6=89=8B=E6=97=B6=EF=BC=8C=E4=BC=9A=E6=9C=89=E5=B0=8F=E6=A6=82?= =?UTF-8?q?=E7=8E=87=E5=9C=A8=E8=BF=9B=E8=A1=8C=E5=AF=86=E9=92=A5=E5=8D=8F?= =?UTF-8?q?=E5=95=86=E5=89=8D=EF=BC=8Ctcp=E6=B5=81=E5=8D=A1=E4=BD=8F?= =?UTF-8?q?=EF=BC=8C=E5=AF=BC=E8=87=B3=E4=B8=8D=E8=83=BD=E6=9C=89=E6=95=88?= =?UTF-8?q?timeout=E8=A1=8C=E4=B8=BA=20(#1842)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lualib/http/httpc.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lualib/http/httpc.lua b/lualib/http/httpc.lua index 78cab15e..bc18dad0 100644 --- a/lualib/http/httpc.lua +++ b/lualib/http/httpc.lua @@ -83,9 +83,6 @@ local function connect(host, timeout) end -- print("protocol hostname port", protocol, hostname, port) local interface = gen_interface(protocol, fd, hostname) - if interface.init then - interface.init() - end if timeout then skynet.timeout(timeout, function() if not interface.finish then @@ -93,6 +90,9 @@ local function connect(host, timeout) end end) end + if interface.init then + interface.init() + end return fd, interface, host end