On Fri Jan 27 08:56:05 2023 +0000, Stefan Dösinger wrote:
I can't say much about this, except that I have run into the sharing restriction on Windows XP and Windows 7 when I tried to use wined3d on Windows, with multithreaded applications, before we had CSMT. Does the application from bug 11436 work on Windows machines where the test passes?
I tested a 64-bit Windows 7 machine with an Nvidia GeForce GTX 580 and it both passes the test and runs Pepakura Designer without error. Most likely this is simply because both AMD and Nvidia always permit sharing lists from a source context to a destination context that has already been made current. We can't do that in GLX, but we can instead do the equivalent operation of sharing the lists from the destination context to the source context that has not been current yet.
The patch I am proposing does the same if the context is already sharing as if the context has already been made current. That means that it permits sharing from a source context to a destination context that is already sharing (by sharing from the destination to the source instead). Nvidia doesn't allow that, but AMD does, so we're just preferring AMD behavior over Nvidia behavior, which is unlikely to break anything. However, I could easily change the patch to preserve that restriction and still fix Pepakura Designer.