uwac: Do not unconditionally set pendingBuffer on configure

If pendingBuffer is set when it was otherwise NULL, then
UwacWindowSubmitBuffer will forever bail early, waiting for a frame
callback that will never come.
This commit is contained in:
Kenny Levinsen 2019-07-25 13:53:44 +02:00 committed by akallabeth
parent 7dda8362e7
commit 4df57d915d

View File

@ -147,7 +147,9 @@ static void xdg_handle_toplevel_configure(void *data,
return;
}
window->drawingBuffer = window->pendingBuffer = &window->buffers[0];
window->drawingBuffer = &window->buffers[0];
if (window->pendingBuffer != NULL)
window->pendingBuffer = window->drawingBuffer;
}
else
{
@ -230,7 +232,9 @@ static void ivi_handle_configure(void* data, struct ivi_surface* surface,
return;
}
window->drawingBuffer = window->pendingBuffer = &window->buffers[0];
window->drawingBuffer = &window->buffers[0];
if (window->pendingBuffer != NULL)
window->pendingBuffer = window->drawingBuffer;
}
else
{
@ -286,7 +290,9 @@ void shell_configure(void* data, struct wl_shell_surface* surface, uint32_t edge
return;
}
window->drawingBuffer = window->pendingBuffer = &window->buffers[0];
window->drawingBuffer = &window->buffers[0];
if (window->pendingBuffer != NULL)
window->pendingBuffer = window->drawingBuffer;
}
else
{