avformat/file: use proper return value in file_close
Signed-off-by: Marton Balint <cus@passwd.hu>
This commit is contained in:
parent
34aee50a7f
commit
722d28db12
|
@ -266,7 +266,8 @@ static int64_t file_seek(URLContext *h, int64_t pos, int whence)
|
||||||
static int file_close(URLContext *h)
|
static int file_close(URLContext *h)
|
||||||
{
|
{
|
||||||
FileContext *c = h->priv_data;
|
FileContext *c = h->priv_data;
|
||||||
return close(c->fd);
|
int ret = close(c->fd);
|
||||||
|
return (ret == -1) ? AVERROR(errno) : 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int file_open_dir(URLContext *h)
|
static int file_open_dir(URLContext *h)
|
||||||
|
|
Loading…
Reference in New Issue