After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 306617 - brush/pattern temp files not cleaned up with stingy-memory-use turned on
brush/pattern temp files not cleaned up with stingy-memory-use turned on
Status: RESOLVED FIXED
Product: GIMP
Classification: Other
Component: General
2.2.x
Other Windows
: Normal minor
: 2.2
Assigned To: GIMP Bugs
GIMP Bugs
Depends on:
Blocks:
 
 
Reported: 2005-06-06 06:28 UTC by Ulrich.Windl
Modified: 2008-01-15 12:55 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
ZIP ARchive with a sample "tmp" directory, as well as "diff -ur" of old and new dot-gimp directories (725.11 KB, application/zip)
2005-06-08 06:12 UTC, Ulrich.Windl
Details

Description Ulrich.Windl 2005-06-06 06:28:23 UTC
Please describe the problem:
I notices a lot of small files (a few bytes to a few kilobytes) in GIMP's "tmp"
directory after GIMP was shut down. Traking the problem I found out that these
files are created during startup of GIMP.

Steps to reproduce:
1. Empty the "tmp" directory of GIMP (similar to ~/.gimp*/tmp/) when GIMP is not
running
2. Start GIMP and then look into the directory
3. Terminate GIMP, look into the directory again


Actual results:
A lot of new files are created during startup, and they are not deleted during
shutdown

Expected results:
Temporary files should be removed after each GIMP session

Does this happen every time?
Yes (AFAIK)

Other information:
I think this effect was not there in previous versions of GIMP
Comment 1 Sven Neumann 2005-06-06 15:21:53 UTC
What kind of temporary files are these?
Comment 2 Ulrich.Windl 2005-06-07 06:38:47 UTC
What kind is a "kind of file"? (Can you elaborate?) The files are binary files.
Do you need an example archive of those? Can't you reproduce?
Comment 3 Manish Singh 2005-06-07 07:00:33 UTC
No, we can't reproduce. Merely starting the GIMP does not create any temporary
files. Are you sure you're telling us the *exact* steps of what you're doing? If
you move your ~/.gimp-2.2 directory out of the way and start from defaults, does
it happen?

Feel free to attach an archive of the files here if you can't tell what they are
yourself.
Comment 4 Ulrich.Windl 2005-06-08 06:10:24 UTC
Reproducing the problem, I found out that the files are created before plugins
are scanned (i.e. quite early). I also found out that when removing the dot-gimp
directory, the problem vanished with using new defaults.
Comment 5 Ulrich.Windl 2005-06-08 06:12:02 UTC
Created attachment 47413 [details]
ZIP ARchive with a sample "tmp" directory, as well as "diff -ur" of old and new dot-gimp directories
Comment 6 Manish Singh 2005-06-08 06:50:04 UTC
Ah, you had stingy-memory-use turned on. Probably this code should be simply
removed, it's really not that useful anymore; the GUI pref has already vanished.
Comment 7 Sven Neumann 2005-06-08 10:45:48 UTC
Right, I wanted to get rid of that code for GIMP 2.4 anyway.
Comment 8 Sven Neumann 2005-06-08 11:28:49 UTC
Done in the HEAD branch. I don't see a point in trying to do anything about this
problem in the stable tree. The preference option is off by default and there's
no GUI to enable it. Closing as FIXED.

2005-06-08  Sven Neumann  <sven@gimp.org>

	Removed "stingy-memory-use" all over the place. This feature was
	really not that useful anymore. The GUI for the preference option
	was already removed for GIMP 2.2.  Fixes bug #306617.

	* app/config/gimpbaseconfig.[ch]: set IGNORE flag on
	"stingy-memory-use".

	* app/config/gimpcoreconfig.h: added a comment that the
	font_path_writable variable is unused.

	* app/base/temp-buf.[ch]: removed code that used to deal with
	swapping temp-bufs to disk.

	* app/base/base.c: made base_config a static variable.
	
	* app/core/gimpdata.[ch]
	* app/core/gimpdatafactory.[ch]: removed stingy_memory_use
	parameter from data construction methods.

	* app/core/gimp-gradients.c
	* app/core/gimpbrush-load.[ch]
	* app/core/gimpbrush.[ch]
	* app/core/gimpbrushgenerated.[ch]
	* app/core/gimpbrushpipe.[ch]
	* app/core/gimpcontext.c
	* app/core/gimpgradient-load.[ch]
	* app/core/gimpgradient.[ch]
	* app/core/gimppalette-import.c
	* app/core/gimppalette.[ch]
	* app/core/gimppattern.[ch]: changed accordingly.
Comment 9 Ulrich.Windl 2005-06-08 11:56:50 UTC
In reply to "I don't see a point in trying to do anything about this
problem in the stable tree. The preference option is off by default and there's
no GUI to enable it.":

An option is inactive if it's ignored from the configuration files (even better:
warn about an option being obsolete), but not when it's no longer offered in a
GUI. The use has no chance to turn it off then. When on, the stable release
makes some nonsense. I wouldn't consider the problem to be fixed, unless you
postulate that old configuration settings have to be deleted for any new version
(which would bee poor software design IMHO).
Comment 10 weskaggs 2005-06-08 18:00:12 UTC
I think perhaps you did not quite understand what Sven was saying.  What he
meant,  I believe, is that any change as extensive as this runs a risk of
breaking something, and the problem, although it certainly exists, is not
serious enough to make it worth running that risk in the stable branch.  After
all, you only provoked the problem by hand-editing the configuration file, and
not very many people are going to be doing that.
Comment 11 Sven Neumann 2005-06-08 23:19:08 UTC
Ulrich is right, we should disable the feature in the 2.2 branch. That is a
simple fix that bears no risk of breaking anything.
Comment 12 Sven Neumann 2005-06-08 23:22:38 UTC
2005-06-09  Sven Neumann  <sven@gimp.org>

	* app/config/gimpbaseconfig.c: ignore the user setting for
	"stingy-memory-use" and use the default value which is FALSE.
	Fixes bug #306617 for the stable branch.

Comment 13 Ulrich.Windl 2005-06-09 06:21:33 UTC
In reply tom comment #10: How can you say that I hand-edited the configuration
file? Once when there was a GUI checkbox for the option, I had selected it.
Since then it remained in my configuration file. I also agree that any change
may break something. However in the current state the option was parsed without
warning (as well as being activated), even though (it seems to me) some
essential code for handling that option had been removed or modified that it
introduced the problem I have described inhere.
Comment 14 Sven Neumann 2005-06-09 19:09:13 UTC
Nothing was altered or removed, the "stingy-memory-use" simply thing has been
broken for ages.
Comment 15 Ulrich.Windl 2005-09-12 13:17:46 UTC
With an unmodified user profile, the problem still appears with GIMP-2.2.8.
Comment 16 Sven Neumann 2005-09-12 19:02:47 UTC
How does the problem still appear? The setting in your gimprc should be ignored.
Comment 17 Ulrich.Windl 2005-09-15 14:26:26 UTC
WHen I suffered from the problem, I had renamed my "do GIMP" directory and let
GIMP create a new one. The problem went away then. After upgrading to the newer
version I put back the original "dot GIMP" directory, and the problem is back
also. For me this means the setting is still recognized and used.