Re: gdk-pixbuf: *no* save xpm patch
- From: Hans Breuer <hans breuer org>
- To: Tor Lillqvist <tml iki fi>, gtk-devel-list gnome org
- Subject: Re: gdk-pixbuf: *no* save xpm patch
- Date: Wed, 01 Nov 2000 11:25:41 +0100
At 10:53 01.11.00 +0200, Tor Lillqvist wrote:
>> context->tempname = g_strdup ("/tmp/gdkpixbuf-xpm-tmp.XXXXXX");
>
>Also here we should use g_get_tmp_dir() and not hardcode /tmp. Plus
>the G_DIR_SEPARATOR stuff, and avoid double separators, as in
>io-tiff.c.
>
Yepp. Should have been more careful ...
>Maybe GLib should have a g_mkstemp_in_tmp_dir(void) (or whatever) that
>would handle the naming of the file and locating it in the preferred
>temp directory?
>
But than the filename wouldn't be owned by the caller anymore and the
ability to identify temp names would be lost.
What about g_get_tmp_filename("gdkpixbuf-xpm-tmp") to get the best of both
worlds?
Hans
-------- Hans "at" Breuer "dot" Org -----------
Tell me what you need, and I'll tell you how to
get along without it. -- Dilbert
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]