GNOME Bugzilla – Bug 699625
Gimp memory leak when jdownloader is also running
Last modified: 2018-05-24 13:42:03 UTC
When both GIMP and jdownloader are running, gimp memory usage increases rapidly until the system runs out of memory. The system then freezes. In order to reproduce this bug, launch jdownloader (you do need to download anything) and then launch GIMP. Load an .xcf file, preferably a rather big one with many layers. The mouse pointer will usually start flickering at this point. Now use the erase tool. You may have to use the tool two or three times. Soon after, GIMP memory usage will start to increase rapidly, even if you do not do anything, until the system runs out of memory. Shutting down jdownloader will halt the memory leak, but GIMP will not release the extra memory. The bug appears in Debian Testing 64 bit and Linux Mint 13 64 bit. It was present in GIMP 2.6 as well. I have not tested the above bug in any other distributions, so i do not know if it appears there as well.
Did you ask the jdownloader developers if they have an idea why this might be happening?
No, i haven't (yet). Mostly because it is GIMP that increases its memory usage until the system runs out of memory in this situation, not jdownloader, so i decided to report it here first.
I just reported the bug to the jdownloader developers as well. http://board.jdownloader.org/showthread.php?p=252720#post252720
BTW, as suspected, this sort of software comes with the usual unwanted by-pack: http://board.jdownloader.org/showthread.php?t=44832 So you should check if any of the troja^wtoolbars or other utilities you got is responsible for that behavior. Maybe something is grabbing the mouse pointer to check what you click on.
I run Linux, not Window$. I can see exactly what is running on my system and there aren't any processes there, other the ones i want, one by one.
I made a youtube video to show the problem. http://www.youtube.com/watch?v=Adx4P0Bxo00 As you can see, it seems as if the layer i copied, keeps getting copied to the clipboard, over and over until the system runs out of memory. It only happens when JDownloader is also running. Other programs are not affected.
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=573113 I wonder if GIMP should be doing something else, or JDownloader. The thread in your from mentions a possible bug in Photoshop what exhibited the same symptoms, but given that that software is closed source we will never know whether they just added a workaround (e.g. "if jdownloader is running, don't bother to update the clipboard-based stuff in our app"). Looking at this in floss software on both ends might finally shed light on the actual cause. In the meantime, disable the link grabbing.
Yes, by disabling JD clipboard monitoring the problem disappears.
From the jdownloader forum thread: <+jiaz> its a gimp issue <+jiaz> Toolkit.getDefaultToolkit().getSystemClipboard().getContents(null) <+jiaz> gimp is preparing the content of clipboard but not freeing it again <+jiaz> grabbing content of clipboard = gimp will create new content, not free old one <+jiaz> every time
I can reproduce exactly the same symptoms (ever increasing memory consumption without any user interaction) when I copy something in gimp, and then repeatedly launch: tools/test-clipboard -t image/png -p /tmp/foo.png And abort it by crtl+c. If I don't abort, GIMP's memory consumption doesn't change at all. If I try aborting often enough, something gets into a loop (and it's probably not GIMP), and consumes insane amounts of memory. At some point, this warning happens over and over again: (gimp-2.9:5354): Gdk-CRITICAL **: IA__gdk_window_get_events: assertion `GDK_IS_WINDOW (window)' failed The stack trace is:
+ Trace 231909
Which involves _gtk_selection_request() in frame #5. To me it looks like the aborted selection operation messes up things. This is clearly a bug in GIMP/GTK+/whatever and should be fixed, but couldn't jdownloader be changed not to do this?
*** Bug 697443 has been marked as a duplicate of this bug. ***
I'm seeing similar strange interactions between Gimp and Netbeans (also a Java-app). If both programs run simultaneously Gimp can start consuming huge amounts of memory and CPU whenever I highlight and jump between files in the Netbeans file explorer. It also causes slugishness in Netbeans (Gimp CPU usage is rather high while interacting with Netbeans). The memory is never freed by Gimp. In one instance I killed Gimp after it reached 11GB of memory usage, system has 16GB. - Gimp v2.8.10, Ubuntu 14.04 x86-64. - Netbeans 8 running on Oracle JVM 1.7.0_65. Bottom line: this is not just a problem together with jdownloader. Might be more generic with Java-based Swing apps or something.
You could ask the Netbeans developers if they grab clipboard like jodownloader.
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gimp/issues/471.