Skip to content

rdp/rdpgfx: Use correct GMainContext for protocol reset source

Quoting the main commit here:

The protocol reset source is supposed to run in the graphics thread.
To do that, it needs to be attached to the pipeline context.
Currently, however, the protocol reset source is attached to a
GMainContext, when the pipeline context is not yet set, which results
in a situation, where the protocol reset source is attached to the
default main context, which runs on the main thread.

For the initial RDPGFX protocol reset, this should not cause any
problems.
However, for subsequent resets, this may result into undefined
behaviour, since currently a subsequent protocol reset can happen during
encode operations of the graphics thread.

To fix this issue, simply create the protocol reset source, when the
pipeline context is actually available.

Merge request reports