avformat/nutdec: Return error on EOF from get_str()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 6bbb2f8f4d)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
fd1be2bd87
commit
9dd9090b89
1 changed files with 2 additions and 0 deletions
|
|
@ -49,6 +49,8 @@ static int get_str(AVIOContext *bc, char *string, unsigned int maxlen)
|
|||
if (maxlen)
|
||||
string[FFMIN(len, maxlen - 1)] = 0;
|
||||
|
||||
if (bc->eof_reached)
|
||||
return AVERROR_EOF;
|
||||
if (maxlen == len)
|
||||
return -1;
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue