Bug 535526 - updateiconcache.c: using open/close without prototype

2008-05-29  Tor Lillqvist  <tml@novell.com>

	Bug 535526 - updateiconcache.c: using open/close without prototype

	* gtk/updateiconcache.c: Include <io.h> if _MSC_VER. Also, use
	g_utime() instead of utime() for UTF-8 pathname support on Windows
	when available.


svn path=/trunk/; revision=20238
This commit is contained in:
Tor Lillqvist 2008-05-29 18:22:38 +00:00 committed by Tor Lillqvist
parent 0fb31a06bb
commit 776c50947e
2 changed files with 14 additions and 1 deletions

View File

@ -1,3 +1,11 @@
2008-05-29 Tor Lillqvist <tml@novell.com>
Bug 535526 - updateiconcache.c: using open/close without prototype
* gtk/updateiconcache.c: Include <io.h> if _MSC_VER. Also, use
g_utime() instead of utime() for UTF-8 pathname support on Windows
when available.
2008-05-29 Jan Arne Petersen <jpetersen@jpetersen.org>
Bug 56355 GtkLabel - Not all changes propagate correctly

View File

@ -31,6 +31,7 @@
#endif
#include <errno.h>
#ifdef _MSC_VER
#include <io.h>
#include <sys/utime.h>
#else
#include <utime.h>
@ -1547,8 +1548,12 @@ build_cache (const gchar *path)
utime_buf.actime = path_stat.st_atime;
utime_buf.modtime = cache_stat.st_mtime;
#if GLIB_CHECK_VERSION (2, 17, 1)
g_utime (path, &utime_buf);
#else
utime (path, &utime_buf);
#endif
if (!quiet)
g_printerr (_("Cache file created successfully.\n"));
}