mirror of
https://github.com/ossrs/srs.git
synced 2025-02-12 19:31:53 +00:00
HttpConn: judge nb_chunk no memory address. (#3465)
Co-authored-by: john <hondaxiao@tencent.com>
This commit is contained in:
parent
2708752a9b
commit
5067e220ca
1 changed files with 3 additions and 1 deletions
|
@ -1162,7 +1162,9 @@ srs_error_t SrsHttpResponseReader::read_chunked(void* data, size_t nb_data, ssiz
|
|||
if (nb_chunk <= 0) {
|
||||
// for the last chunk, eof.
|
||||
is_eof = true;
|
||||
*nb_read = 0;
|
||||
if (nb_read) {
|
||||
*nb_read = 0;
|
||||
}
|
||||
} else {
|
||||
// for not the last chunk, there must always exists bytes.
|
||||
// left bytes in chunk, read some.
|
||||
|
|
Loading…
Reference in a new issue