From 7e52a0584f2ec6f355f696d84d24e1dae4079280 Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Thu, 28 Oct 2004 03:04:10 +0000 Subject: [PATCH] Include gstdio.h and use g_open(). 2004-10-28 Tor Lillqvist * glib/gkeyfile.c: Include gstdio.h and use g_open(). --- ChangeLog | 4 ++++ ChangeLog.pre-2-10 | 4 ++++ ChangeLog.pre-2-12 | 4 ++++ ChangeLog.pre-2-6 | 4 ++++ ChangeLog.pre-2-8 | 4 ++++ glib/gkeyfile.c | 7 ++++--- 6 files changed, 24 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index b83598f..651a58c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2004-10-28 Tor Lillqvist + + * glib/gkeyfile.c: Include gstdio.h and use g_open(). + 2004-10-27 Ray Strode * glib/gkeyfile.c: diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index b83598f..651a58c 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,7 @@ +2004-10-28 Tor Lillqvist + + * glib/gkeyfile.c: Include gstdio.h and use g_open(). + 2004-10-27 Ray Strode * glib/gkeyfile.c: diff --git a/ChangeLog.pre-2-12 b/ChangeLog.pre-2-12 index b83598f..651a58c 100644 --- a/ChangeLog.pre-2-12 +++ b/ChangeLog.pre-2-12 @@ -1,3 +1,7 @@ +2004-10-28 Tor Lillqvist + + * glib/gkeyfile.c: Include gstdio.h and use g_open(). + 2004-10-27 Ray Strode * glib/gkeyfile.c: diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index b83598f..651a58c 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,7 @@ +2004-10-28 Tor Lillqvist + + * glib/gkeyfile.c: Include gstdio.h and use g_open(). + 2004-10-27 Ray Strode * glib/gkeyfile.c: diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index b83598f..651a58c 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,7 @@ +2004-10-28 Tor Lillqvist + + * glib/gkeyfile.c: Include gstdio.h and use g_open(). + 2004-10-27 Ray Strode * glib/gkeyfile.c: diff --git a/glib/gkeyfile.c b/glib/gkeyfile.c index 6148078..5f9115b 100644 --- a/glib/gkeyfile.c +++ b/glib/gkeyfile.c @@ -51,6 +51,7 @@ #include "gslist.h" #include "gmem.h" #include "gmessages.h" +#include "gstdio.h" #include "gstring.h" #include "gstrfuncs.h" #include "gutils.h" @@ -300,7 +301,7 @@ find_file_in_data_dirs (const gchar *file, path = g_build_filename (data_dir, sub_dir, candidate_file, NULL); - fd = open (path, O_RDONLY); + fd = g_open (path, O_RDONLY, 0); if (output_file != NULL) *output_file = g_strdup (path); @@ -432,7 +433,7 @@ g_key_file_load_from_fd (GKeyFile *key_file, /** * g_key_file_load_from_file: * @key_file: an empty #GKeyFile struct - * @file: the path of a filename to load + * @file: the path of a filename to load, in the GLib file name encoding * @flags: flags from #GKeyFileFlags * @error: return location for a #GError, or %NULL * @@ -455,7 +456,7 @@ g_key_file_load_from_file (GKeyFile *key_file, g_return_val_if_fail (key_file != NULL, FALSE); g_return_val_if_fail (file != NULL, FALSE); - fd = open (file, O_RDONLY); + fd = g_open (file, O_RDONLY, 0); if (fd < 0) { -- 2.7.4