Harden playback/cache path for malformed media and concurrent timeline updates#1035
Open
Harden playback/cache path for malformed media and concurrent timeline updates#1035
Conversation
…e updates - Invalidate timeline cache on ApplyJsonDiff() clip insert (remove affected frame range). - Add lock in Timeline::ClearAllCache() for safe concurrent access. - Make VideoCacheThread cross-thread state safe (atomics + seek-state mutex). - Lock CacheMemory::Contains() to avoid races. - Handle malformed audio streams in FFmpegReader by disabling invalid audio and continuing video-only. - Add FPS/timebase safety fallbacks in FFmpeg frame/PTS math. - Guard Frame::GetSamplesPerFrame() against invalid inputs. - Add/adjust regression tests for cache invalidation and invalid rate handling.
Member
Author
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #1035 +/- ##
===========================================
- Coverage 59.69% 59.63% -0.06%
===========================================
Files 206 206
Lines 20567 20692 +125
===========================================
+ Hits 12277 12340 +63
- Misses 8290 8352 +62 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Merge conflicts have been detected on this PR, please resolve. |
# Conflicts: # src/Qt/VideoCacheThread.cpp
… available (instead of the atomic ones)
- Disable audio when decoder sample format is invalid (AV_SAMPLE_FMT_NONE).
- Only synthesize channel layout when reported channels are actually valid (> 0).
- src/AudioReaderSource.cpp
- Added progress/validity guards in getNextAudioBlock() to prevent infinite loops on corrupt/empty audio frames.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Harden playback/cache path for malformed media and concurrent timeline updates