Browse Source

【修复】chunk 模式下获取 chunk size 失败问题

Signed-off-by: chenyong <1521761801@qq.com>
chenyong 7 years ago
parent
commit
8971d528e2
2 changed files with 3 additions and 0 deletions
  1. 2 0
      README.md
  2. 1 0
      src/webclient.c

+ 2 - 0
README.md

@@ -66,6 +66,8 @@ RT-Thread online packages
                Version (latest)  --->
 ```
 
+**Enable debug log output**:开启调试日志显示,可以用于查看请求和响应的头部数据信息;
+
 **Enable webclient GET/POST samples** :添加示例代码;
 
 **Select TLS mode** :配置开启 HTTPS 支持,选择支持的模式;

+ 1 - 0
src/webclient.c

@@ -1095,6 +1095,7 @@ static int webclient_next_chunk(struct webclient_session *session)
 
     RT_ASSERT(session);
 
+    rt_memset(line, 0x00, sizeof(line));
     length = webclient_read_line(session, line, sizeof(line));
     if (length > 0)
     {