bytedeco/javacv

Error on InputStream.read(): java.io.IOException: closed

Open

#2,049 opened on Jun 29, 2023

View on GitHub
 (3 comments) (0 reactions) (0 assignees)Java (1,583 forks)batch import
bughelp wanted

Repository metrics

Stars
 (6,985 stars)
PR merge metrics
 (No merged PRs in 30d)

Description

When I use FFmpegFrameGrabber(InputStream) and the InputStream is closed, I only get the message on stderr: Error on InputStream.read(): java.io.IOException: closed FFmpegFrameGrabber#grab then still waits in line 1454 pkt.stream_index(-1); infinitly.

I would appreciate, if FFmpegFrameGrabber#grab would return a null Frame, so I can take appropriate action. Even better would be, if FFmpegFrameGrabber#grab throws that java.io.IOException.

Contributor guide