We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug https下载文件中,协议中,Range:设置范围是不是应该从0开始,而不是从1开始,该文件是:ota_https.c,版本号是: SHA-1:1d90ab9bb4cdcb654d16fbdd5f039c13a9f6c48e
To Reproduce Steps to reproduce the behavior:
Expected behavior 正常应该是从ota文件第一字节开始传输,而不是从第二字节传输,http文件下载协议是range字段设置是从0开始的,不是从1开始
Current behavior 当前表现,云端会直接从发ota文件第二字节数据,最后数据少发送1字节,并且超时(因为实际接收字节数与期望接收字节数不一致)
Please tell us about your environment:
Other information (当前经过修改后代码如下,设置range从0开始后,云端返回数据就正常,但没有对section->len进行判断(如果为0,那该range字段应该是错误的):)
static int http_makerequest(http_section_t *section) { int ret; ret = snprintf((char *)section->cache,CONFIG_HTTPS_DOWNLOADING_BLKLEN,CN_OTA_HTTPS_REQ_FMT,section->url_re,\ section->bearer,section->host,section->port,section->offset , section->offset + section->len -1); ///< start from 1 return ret; }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Describe the bug
https下载文件中,协议中,Range:设置范围是不是应该从0开始,而不是从1开始,该文件是:ota_https.c,版本号是:
SHA-1:1d90ab9bb4cdcb654d16fbdd5f039c13a9f6c48e
To Reproduce
Steps to reproduce the behavior:
static int http_makerequest(http_section_t *section)
{
int ret;
ret = snprintf((char *)section->cache,CONFIG_HTTPS_DOWNLOADING_BLKLEN,CN_OTA_HTTPS_REQ_FMT,section->url_re,
section->bearer,section->host,section->port,section->offset + 1, section->offset + section->len); ///< start from 1
return ret;
}
这样的话云端返回数据第一字节就已经不匹配了
Expected behavior
正常应该是从ota文件第一字节开始传输,而不是从第二字节传输,http文件下载协议是range字段设置是从0开始的,不是从1开始
Current behavior
当前表现,云端会直接从发ota文件第二字节数据,最后数据少发送1字节,并且超时(因为实际接收字节数与期望接收字节数不一致)
Please tell us about your environment:
Other information (当前经过修改后代码如下,设置range从0开始后,云端返回数据就正常,但没有对section->len进行判断(如果为0,那该range字段应该是错误的):)
The text was updated successfully, but these errors were encountered: