mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice
synced 2025-12-26 14:41:25 +00:00
Respond to clipb request with an unsupported type with data with a none type
Currently we send a VD_AGENT_CLIPBOARD_RELEASE when we receive a VD_AGENT_CLIPBOARD_REQUEST with a type which we do not support. This is not correct, as this means given up clipboard ownership while we may be able to answer requests with different types. The correct response is to nack the request by sending a VD_AGENT_CLIPBOARD (data) message with a type of VD_AGENT_CLIPBOARD_NONE.
This commit is contained in:
parent
a2d645ffe3
commit
bc9f00961f
@ -1095,7 +1095,7 @@ void RedClient::dispatch_agent_message(VDAgentMessage* msg, void* data)
|
||||
break;
|
||||
case VD_AGENT_CLIPBOARD_REQUEST:
|
||||
if (!Platform::request_clipboard_notification(((VDAgentClipboardRequest*)data)->type)) {
|
||||
send_agent_clipboard_message(VD_AGENT_CLIPBOARD_RELEASE);
|
||||
on_clipboard_notify(VD_AGENT_CLIPBOARD_NONE, NULL, 0);
|
||||
}
|
||||
break;
|
||||
case VD_AGENT_CLIPBOARD_RELEASE:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user