We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 4924

Summary: wl_data_device_manager bind is missing version check
Product: SDL Reporter: Michael Forney <mforney>
Component: videoAssignee: Sam Lantinga <slouken>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2    
Version: HG 2.1   
Hardware: x86_64   
OS: Linux   
Attachments: Patch fixing the issue
Alternative patch to support wl_data_device_manager < 3

Description Michael Forney 2020-01-03 02:08:46 UTC
Created attachment 4146 [details]
Patch fixing the issue

When the wayland video driver sees a wl_data_device_manager global, it binds it as version 3, even if that is newer than the version supported by the compositor. This will result in a protocol error, even though SDL could continue if the global was not even present.

Attached is a patch to fix the issue.
Comment 1 Michael Forney 2020-01-03 06:39:54 UTC
Created attachment 4147 [details]
Alternative patch to support wl_data_device_manager < 3

I attached another patch as an alternative which supports wl_data_device_manager versions 1 and 2 by making the wl_data_offer_set_actions request conditional on the version being >= 3.
Comment 2 Sam Lantinga 2020-01-03 22:24:30 UTC
Your second patch is in, thanks!
https://hg.libsdl.org/SDL/rev/d984274996dd