[Bug 41949] New: Pasting into IDA Pro stops working on macOS
https://bugs.winehq.org/show_bug.cgi?id=41949 Bug ID: 41949 Summary: Pasting into IDA Pro stops working on macOS Product: Wine Version: unspecified Hardware: x86 OS: Mac OS X Status: UNCONFIRMED Severity: normal Priority: P2 Component: winemac.drv Assignee: wine-bugs(a)winehq.org Reporter: vit9696(a)avp.su There already is a report regarding a regression introduced in the recent wine versions (somewhere after 1.9.15) regarding IDA Pro clipboard issues #41710. However, there is one more winemac-specific bug, existing in all known wine versions of at least 1.9.x branch. Basically IDA stops receiving macOS clips after anything is copied from IDA to macOS. To reproduce this the following steps need to be performed: 1. Load any binary (e.g. by dragging it into IDA window); 2. Select any text and press Ctrl+C; 3. Paste it anywhere on your mac (e.g. press Cmd+V in TextEdit.app); 4. Now select any other text in a native app and copy it (e.g. press Cmd+C in TextEdit.app); 5. Paste this text into any field in IDA (e.g. press g, then Ctrl+V). What will happen at the 5th step is IDA getting data copied at the 2nd step instead of the 4th. Newer wine versions might additionally cause a crash at the 2nd step (due to #41710). Older wine versions (e.g. 1.9.15) have no such issue. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=41949 Ken Thomases <ken(a)codeweavers.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |ken(a)codeweavers.com --- Comment #1 from Ken Thomases <ken(a)codeweavers.com> --- I was not able to reproduce this in current Wine. IDA Pro catches an exception at step 2, due to bug 41710. (I haven't seen it crash, as such.) Because of that, trying to paste at step 3 doesn't work. There's nothing on the clipboard to paste. I then copy some text from a Mac app and can paste it just fine into IDA Pro. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=41949 Ken Thomases <ken(a)codeweavers.com> changed: What |Removed |Added ---------------------------------------------------------------------------- URL| |https://www.hex-rays.com/pr | |oducts/ida/support/download | |_demo.shtml Keywords| |download -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=41949 --- Comment #2 from Vit <vit9696(a)avp.su> --- Repeat step 2 once more after seeing the exception message. This time it will *likely* copy data just fine. Then proceed with the next instructions. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=41949 Austin English <austinenglish(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |regression --- Comment #3 from Austin English <austinenglish(a)gmail.com> --- What version of wine are you using? Can you run a regression test: https://wiki.winehq.org/RegressionTesting -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=41949 --- Comment #4 from Vit <vit9696(a)avp.su> --- (In reply to Austin English from comment #3)
What version of wine are you using? Can you run a regression test: https://wiki.winehq.org/RegressionTesting
I have used almost all 1.9.x versions, as well as the previous branches. If I remember correctly, it is not a regression, it has always been like that with mac driver. X11 has no such issue. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=41949 Ken Thomases <ken(a)codeweavers.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|wine-bugs(a)winehq.org |ken(a)codeweavers.com Status|UNCONFIRMED |NEW Ever confirmed|0 |1 --- Comment #5 from Ken Thomases <ken(a)codeweavers.com> --- Created attachment 56345 --> https://bugs.winehq.org/attachment.cgi?id=56345 Patch to update clipboard when process activates Please give this patch a try. The issue is that, when IDA Pro gets focus back (after having switched to another app), it checks which window owns the clipboard. If it's still its own window, it then opens the clipboard, empties it, and re-sets its own data to it. In the current code, user32 only asks the Mac driver to update the clipboard when the clipboard is opened. It doesn't ask when the app checks the ownership. So, at the time of the ownership test, the Mac driver hasn't noticed that another app has grabbed the clipboard, and IDA Pro is told that it still owns the clipboard. That changes once it opens the clipboard — at that point the Mac driver does notice that another app has grabbed the clipboard — but by that point it's too late. IDA Pro has already set out to overwrite the clipboard. This patch makes the Mac driver check if another app has grabbed the clipboard when it's made the active app. That happens before IDA Pro is told. So, IDA Pro sees that it's no longer the owner of the clipboard and doesn't overwrite it. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=41949 --- Comment #6 from Vit <vit9696(a)avp.su> --- Interesting explanation and quite insane behaviour. But the patch appears to have worked. Good job. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=41949 Ken Thomases <ken(a)codeweavers.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Fixed by SHA1| |e5a9055dacf0a3dc7d232016f95 | |3131a2e867f13 Resolution|--- |FIXED --- Comment #7 from Ken Thomases <ken(a)codeweavers.com> --- Fix committed: http://source.winehq.org/git/wine.git/?a=commit;h=e5a9055dacf0a3dc7d232016f9... -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=41949 Alexandre Julliard <julliard(a)winehq.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED --- Comment #8 from Alexandre Julliard <julliard(a)winehq.org> --- Closing bugs fixed in 2.0-rc2. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
participants (1)
-
wine-bugs@winehq.org