@@ -56,8 +56,8 @@ while true do
return
end
- -- 打开文件写入
- file, err = io.open(fullpath, "w+")
+ -- 打开文件写入(Windows 下需用二进制模式)
+ file, err = io.open(fullpath, "wb")
if not file then
ngx.say(cjson.encode({ code = 500, msg = "无法创建文件: " .. (err or ""), data = {} }))