luci-lib-docker: fix chunked decode 5520/head
authorlisaac <lisaac.cn@gmail.com>
Thu, 26 Aug 2021 00:57:55 +0000 (08:57 +0800)
committerRen Zongjia <acooler15@foxmail.com>
Tue, 16 Nov 2021 08:20:08 +0000 (16:20 +0800)
Signed-off-by: Ren Zongjia <acooler15@foxmail.com>
collections/luci-lib-docker/luasrc/docker.lua

index cd9bf132d16d1f5f2039c4fb6e6544cea09a8826..346b0ef23542fe53d3aea457c45bbda6327c8bc2 100644 (file)
@@ -21,7 +21,7 @@ local chunksource = function(sock, buffer)
                local output
                local _, endp, count = buffer:find("^([0-9a-fA-F]+)\r\n")
 
-               if not count then
+               while not count do
                        local newblock, code = sock:recv(1024)
                        if not newblock then
                                return nil, code