-
-
Notifications
You must be signed in to change notification settings - Fork 149
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Core dump running cb with image copied from firefox in the clipboard #201
Comments
Ok, sorry for the wait! This has happened a couple times to me before. The problem has been certain kinds of accesses to arrays somewhere, but they're hard to diagnose because it generally only happens on the very latest compiler versions. If you install CB using something like Flatpak, does that work instead? |
Unable to reproduce so this looks like a "too new" compiler problem, closing if no response soon |
Sorry about not responding earlier, I missed your reply 3 weeks ago. So I tested with the flatpak version, and while the core didn't dump like the prebuilt version from github did, the behaviour isn't exactly as expected either. What happens is it says "There is currently nothing in the clipboard", and then instead of closing, I get a Similar to the prebuilt github version, the flatpak works correctly with images copied from the gimp or chromium. |
Then this is a dupe of #171, the fix is for someone, anyone, to write the C++ code to interface with the special wlroots clipboard protocol |
Is that the same issue as being unable to see the contents of the clipboard when an image has been copied via Firefox? (It sounds like I just happened to run into #171 at the same time, and assumed it was a related bug because they occurred together) |
Not the same, but it still is close-worthy because I've seen this multiple times and the root cause turns out to be that the compiler is too new, leading to subtle bugs like this one that aren't actionable because they depend on the compiler. |
I'm not hitting the crash on the flatpak version though, it just doesn't see the contents of the clipboard there. I'm not sure if the issue is related to the fact that the github version was crashing, but if I understand you correctly, the flatpak version shouldn't be observing the compiler issues? If this is the case I wouldn't mind switching to that, but it still can't interact with images from firefox. |
All Flatpaks use a compiler version that tends to lag behind the latest and greatest, so that's why you don't see the crash there. However, I can't reproduce the Firefox issue, so I'm not sure what to do there. |
So you're right clicking and selecting EDIT: Confirmed- running chromium with |
Then I think I might know the problem: if it gets something, anything, from X11 first, it doesn't check Wayland. There might be some kind of content coming from the X11 side first and that prevents CB from getting anything from Wayland, or in your case, Firefox. |
It is able to get text from firefox and chromium on wayland. Maybe images are handled differently though? |
I'm not sure, but since I almost never use Wayland, I'll need to check that out. |
Let me know if there's any testing I could do that would be helpful, and thanks for looking into this :) |
So I played around a bit, and it seems like when you cat an image into wl-copy then run wl-paste, it outputs the raw image. When you copy an image from firefox however, wl-paste doesn't output anything. Here's the interesting part though, if you then run I'm not sure what the source format looks like, or how it knows to convert to the destination format, but I suspect this is what's tripping cb up. It also means that I can't directly pipe the paste buffer into cb using the script method. |
Describe the bug + To Reproduce
After copying an image to the clipboard from firefox, running
cb
prints the following:This happens both if I compile it myself, as well as when I use the pre-compiled binary on the releases page.
Copying something else to the clipboard fixes the issue. I'm also able to run
cb copy file.jpg
as well as copy the same image in chromium and runcb
without issue, so it's specifically when copying an image from firefox.Version
Version 0.9.0 on ArchLinux using clipboard-linux-amd64.zip from the releases page.
Additional context
I'm not sure if it helps, but I'm running wayland.
The text was updated successfully, but these errors were encountered: