You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug: obs-media-io: deliver video after a callback disconnects #1535
rust/obs-media-io/src/video_output.rs, commit 9f3bd5672 in #1462.
Class
Reentrant callback logic error.
How it is reached
A video callback disconnects itself and shifts the input vector, causing the following subscriber to miss the frame. Track visited registrations rather than mutable vector indices.
Proposed fix and failing test
Carry self_disconnect_still_delivers_following_input and its focused fix from #1462; show RED on current master and GREEN after the change.
Decisions
Split from #1462 as requested by the maintainer. This intentionally corrects callback reentry behavior in Rust; ordinary nonreentrant delivery retains the C baseline.
Claiming: split this fix from #1462. 1. Reproduce the callback regression. 2. Carry the individual fix and run media tests. 3. Open and land one PR today.
Decision: a callback/parameter pair already visited for a frame is deferred to the next frame if it reconnects itself. This prevents same-frame reconnection cycles while retaining delivery to other subscribers and newly connected distinct pairs. Regression self_reconnect_waits_for_the_next_frame fails before the additional guard and passes afterward.
Fixed and merged in #1539. Removing a callback no longer skips the following subscriber, and a callback/parameter pair that reconnects itself is deferred to the next frame to prevent repeated same-frame delivery. All 236 media tests pass, and the relevant regressions each passed 100 consecutive runs. No remaining work for this issue.
Activity
zackees commentedon Oct 20, 2026
Claiming: split this fix from #1462. 1. Reproduce the callback regression. 2. Carry the individual fix and run media tests. 3. Open and land one PR today.
test: bound same-frame self-reconnection (Refs #1535)
obs-media-io: defer self-reconnected callbacks to the next frame (Refs …
zackees commentedon Oct 20, 2026
Decision: a callback/parameter pair already visited for a frame is deferred to the next frame if it reconnects itself. This prevents same-frame reconnection cycles while retaining delivery to other subscribers and newly connected distinct pairs. Regression self_reconnect_waits_for_the_next_frame fails before the additional guard and passes afterward.
test: reproduce video-self-disconnect (Refs #1535)
obs-media-io: deliver video after a callback disconnects (Fixes #1535)
test: bound same-frame self-reconnection (Refs #1535)
obs-media-io: defer self-reconnected callbacks to the next frame (Refs …
zackees commentedon Oct 20, 2026
Fixed and merged in #1539. Removing a callback no longer skips the following subscriber, and a callback/parameter pair that reconnects itself is deferred to the next frame to prevent repeated same-frame delivery. All 236 media tests pass, and the relevant regressions each passed 100 consecutive runs. No remaining work for this issue.
obs-media-io: deliver video after a callback disconnects (obs-rust#1539)