Fix deadlock in stream when shouldRender is false

This commit is contained in:
Patrick Nicolas committed 2024-08-20 21:45:41 +02:00
1 parent 0a1a3d2823
commit 0133dd67ca
1 file changed
+5 -2
+5 -2
View File
@@ -358,7 +358,7 @@ void scenes::stream::render(const XrFrameState & frame_state)
session.begin_frame();
session.end_frame(frame_state.predictedDisplayTime, {});
std::unique_lock lock(decoder_mutex);
std::unique_lock lock(frames_mutex);
for (auto & i: decoders)
{
for (auto & frame: i.latest_frames)
@@ -716,7 +716,10 @@ void scenes::stream::render(const XrFrameState & frame_state)
// Network operations may be blocking, do them once everything was submitted
for (const auto & handle: blit_handles)
send_feedback(handle->feedback);
{
if (handle)
send_feedback(handle->feedback);
}
read_actions();