You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
tools/ffhash: close file handle on error
Fixes CID1026768 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
@@ -89,6 +89,7 @@ static int check(char *file)
|
|||||||
for (;;) {
|
for (;;) {
|
||||||
ssize_t size = read(fd, buffer, SIZE);
|
ssize_t size = read(fd, buffer, SIZE);
|
||||||
if (size < 0) {
|
if (size < 0) {
|
||||||
|
close(fd);
|
||||||
finish();
|
finish();
|
||||||
printf("+READ-FAILED: %s", strerror(errno));
|
printf("+READ-FAILED: %s", strerror(errno));
|
||||||
ret = 2;
|
ret = 2;
|
||||||
|
Reference in New Issue
Block a user