Skip to content
  • Jakub Janků's avatar
    clipboard: cancel request for targets on grab from client · 783ceece
    Jakub Janků authored
    
    
    If gtk_clipboard_set_with_data() is invoked between
    gtk_clipboard_request_targets() and the
    GtkClipboardTargetsReceivedFunc callback,
    the targets we eventually receive are no longer valid.
    
    To solve this, cancel the request in vdagent_clipboard_grab().
    
    Otherwise we end up in a situation when vdagent holds
    clipboard grab in the guest but cannot provide data to the
    apps that request it - this can be observed in the log:
    
        CRITICAL **: 20:48:55.782: clipboard_get_cb: assertion 'c->selections[sel_id].owner == OWNER_CLIENT' failed
    
    Signed-off-by: default avatarJakub Janků <jjanku@redhat.com>
    Acked-by: default avatarVictor Toso <victortoso@redhat.com>
    783ceece