Преглед на файлове

fix Chunked transfer chunk_sz parse wrong

U-T3CAIC\zhangqiangqiang преди 3 години
родител
ревизия
e713e190dd
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      src/webclient.c

+ 1 - 1
src/webclient.c

@@ -841,7 +841,7 @@ int webclient_handle_response(struct webclient_session *session)
         char *line = rt_malloc(len);
         /* chunk mode, we should get the first chunk size */
         webclient_read_line(session, line, len);
-        session->chunk_sz = strtol(line, RT_NULL, len);
+        session->chunk_sz = strtol(line, RT_NULL, 16);
         session->chunk_offset = 0;
         rt_free(line);
     }