From e0b563603105e65890d0adc581d6c84cbf611ba9 Mon Sep 17 00:00:00 2001
From: Owen Taylor <otaylor@redhat.com>
Date: Tue, 30 May 2000 20:05:23 +0000
Subject: [PATCH] Move the g_locale_get_codeset() up in the header file to
 correspond to to

Tue May 30 16:01:32 2000  Owen Taylor  <otaylor@redhat.com>

	* glib.h gutils.c: Move the g_locale_get_codeset() up in the
	header file to correspond to to comments about memory
	management. Rename to g_get_codeset() to avoid
	polluting the g_locale_* namespace, which probably
	would have g_locale_get_codeset (GLocale *locale).
	Add a doc comment.
---
 ChangeLog          |  9 +++++++++
 ChangeLog.pre-2-0  |  9 +++++++++
 ChangeLog.pre-2-10 |  9 +++++++++
 ChangeLog.pre-2-12 |  9 +++++++++
 ChangeLog.pre-2-2  |  9 +++++++++
 ChangeLog.pre-2-4  |  9 +++++++++
 ChangeLog.pre-2-6  |  9 +++++++++
 ChangeLog.pre-2-8  |  9 +++++++++
 glib.h             |  5 +++--
 glib/glib.h        |  5 +++--
 glib/gutils.c      | 10 +++++++++-
 gutils.c           | 10 +++++++++-
 12 files changed, 96 insertions(+), 6 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index ba5352d57..5a3d6ac18 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+Tue May 30 16:01:32 2000  Owen Taylor  <otaylor@redhat.com>
+
+	* glib.h gutils.c: Move the g_locale_get_codeset() up in the 
+	header file to correspond to to comments about memory
+	management. Rename to g_get_codeset() to avoid 
+	polluting the g_locale_* namespace, which probably
+	would have g_locale_get_codeset (GLocale *locale).
+	Add a doc comment.
+
 Mon May 29 14:10:35 2000  Owen Taylor  <otaylor@redhat.com>
 
 	* gutils.c (g_locale_get_codeset): Add function to get the 
diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0
index ba5352d57..5a3d6ac18 100644
--- a/ChangeLog.pre-2-0
+++ b/ChangeLog.pre-2-0
@@ -1,3 +1,12 @@
+Tue May 30 16:01:32 2000  Owen Taylor  <otaylor@redhat.com>
+
+	* glib.h gutils.c: Move the g_locale_get_codeset() up in the 
+	header file to correspond to to comments about memory
+	management. Rename to g_get_codeset() to avoid 
+	polluting the g_locale_* namespace, which probably
+	would have g_locale_get_codeset (GLocale *locale).
+	Add a doc comment.
+
 Mon May 29 14:10:35 2000  Owen Taylor  <otaylor@redhat.com>
 
 	* gutils.c (g_locale_get_codeset): Add function to get the 
diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10
index ba5352d57..5a3d6ac18 100644
--- a/ChangeLog.pre-2-10
+++ b/ChangeLog.pre-2-10
@@ -1,3 +1,12 @@
+Tue May 30 16:01:32 2000  Owen Taylor  <otaylor@redhat.com>
+
+	* glib.h gutils.c: Move the g_locale_get_codeset() up in the 
+	header file to correspond to to comments about memory
+	management. Rename to g_get_codeset() to avoid 
+	polluting the g_locale_* namespace, which probably
+	would have g_locale_get_codeset (GLocale *locale).
+	Add a doc comment.
+
 Mon May 29 14:10:35 2000  Owen Taylor  <otaylor@redhat.com>
 
 	* gutils.c (g_locale_get_codeset): Add function to get the 
diff --git a/ChangeLog.pre-2-12 b/ChangeLog.pre-2-12
index ba5352d57..5a3d6ac18 100644
--- a/ChangeLog.pre-2-12
+++ b/ChangeLog.pre-2-12
@@ -1,3 +1,12 @@
+Tue May 30 16:01:32 2000  Owen Taylor  <otaylor@redhat.com>
+
+	* glib.h gutils.c: Move the g_locale_get_codeset() up in the 
+	header file to correspond to to comments about memory
+	management. Rename to g_get_codeset() to avoid 
+	polluting the g_locale_* namespace, which probably
+	would have g_locale_get_codeset (GLocale *locale).
+	Add a doc comment.
+
 Mon May 29 14:10:35 2000  Owen Taylor  <otaylor@redhat.com>
 
 	* gutils.c (g_locale_get_codeset): Add function to get the 
diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2
index ba5352d57..5a3d6ac18 100644
--- a/ChangeLog.pre-2-2
+++ b/ChangeLog.pre-2-2
@@ -1,3 +1,12 @@
+Tue May 30 16:01:32 2000  Owen Taylor  <otaylor@redhat.com>
+
+	* glib.h gutils.c: Move the g_locale_get_codeset() up in the 
+	header file to correspond to to comments about memory
+	management. Rename to g_get_codeset() to avoid 
+	polluting the g_locale_* namespace, which probably
+	would have g_locale_get_codeset (GLocale *locale).
+	Add a doc comment.
+
 Mon May 29 14:10:35 2000  Owen Taylor  <otaylor@redhat.com>
 
 	* gutils.c (g_locale_get_codeset): Add function to get the 
diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4
index ba5352d57..5a3d6ac18 100644
--- a/ChangeLog.pre-2-4
+++ b/ChangeLog.pre-2-4
@@ -1,3 +1,12 @@
+Tue May 30 16:01:32 2000  Owen Taylor  <otaylor@redhat.com>
+
+	* glib.h gutils.c: Move the g_locale_get_codeset() up in the 
+	header file to correspond to to comments about memory
+	management. Rename to g_get_codeset() to avoid 
+	polluting the g_locale_* namespace, which probably
+	would have g_locale_get_codeset (GLocale *locale).
+	Add a doc comment.
+
 Mon May 29 14:10:35 2000  Owen Taylor  <otaylor@redhat.com>
 
 	* gutils.c (g_locale_get_codeset): Add function to get the 
diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6
index ba5352d57..5a3d6ac18 100644
--- a/ChangeLog.pre-2-6
+++ b/ChangeLog.pre-2-6
@@ -1,3 +1,12 @@
+Tue May 30 16:01:32 2000  Owen Taylor  <otaylor@redhat.com>
+
+	* glib.h gutils.c: Move the g_locale_get_codeset() up in the 
+	header file to correspond to to comments about memory
+	management. Rename to g_get_codeset() to avoid 
+	polluting the g_locale_* namespace, which probably
+	would have g_locale_get_codeset (GLocale *locale).
+	Add a doc comment.
+
 Mon May 29 14:10:35 2000  Owen Taylor  <otaylor@redhat.com>
 
 	* gutils.c (g_locale_get_codeset): Add function to get the 
diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8
index ba5352d57..5a3d6ac18 100644
--- a/ChangeLog.pre-2-8
+++ b/ChangeLog.pre-2-8
@@ -1,3 +1,12 @@
+Tue May 30 16:01:32 2000  Owen Taylor  <otaylor@redhat.com>
+
+	* glib.h gutils.c: Move the g_locale_get_codeset() up in the 
+	header file to correspond to to comments about memory
+	management. Rename to g_get_codeset() to avoid 
+	polluting the g_locale_* namespace, which probably
+	would have g_locale_get_codeset (GLocale *locale).
+	Add a doc comment.
+
 Mon May 29 14:10:35 2000  Owen Taylor  <otaylor@redhat.com>
 
 	* gutils.c (g_locale_get_codeset): Add function to get the 
diff --git a/glib.h b/glib.h
index d585282b9..12fa999db 100644
--- a/glib.h
+++ b/glib.h
@@ -1708,12 +1708,13 @@ gchar*  g_path_skip_root	(gchar       *file_name);
 gchar*	g_dirname		(const gchar *file_name);
 gchar*	g_get_current_dir	(void);
 
+/* Get the codeset for the current locale */
+gchar * g_get_codeset    (void);
+
 /* return the environment string for the variable. The returned memory
  * must not be freed. */
 gchar*  g_getenv		(const gchar *variable);
 
-gchar * g_locale_get_codeset    (void);
-
 /* we use a GLib function as a replacement for ATEXIT, so
  * the programmer is not required to check the return value
  * (if there is any in the implementation) and doesn't encounter
diff --git a/glib/glib.h b/glib/glib.h
index d585282b9..12fa999db 100644
--- a/glib/glib.h
+++ b/glib/glib.h
@@ -1708,12 +1708,13 @@ gchar*  g_path_skip_root	(gchar       *file_name);
 gchar*	g_dirname		(const gchar *file_name);
 gchar*	g_get_current_dir	(void);
 
+/* Get the codeset for the current locale */
+gchar * g_get_codeset    (void);
+
 /* return the environment string for the variable. The returned memory
  * must not be freed. */
 gchar*  g_getenv		(const gchar *variable);
 
-gchar * g_locale_get_codeset    (void);
-
 /* we use a GLib function as a replacement for ATEXIT, so
  * the programmer is not required to check the return value
  * (if there is any in the implementation) and doesn't encounter
diff --git a/glib/gutils.c b/glib/gutils.c
index f09715ac2..3b6659841 100644
--- a/glib/gutils.c
+++ b/glib/gutils.c
@@ -761,8 +761,16 @@ g_int_hash (gconstpointer v)
   return *(const gint*) v;
 }
 
+/**
+ * g_get_codeset:
+ * 
+ * Get the codeset for the current locale.
+ * 
+ * Return value: a newly allocated string containing the name
+ * of the codeset. This string must be freed with g_free().
+ **/
 gchar *
-g_locale_get_codeset (void)
+g_get_codeset (void)
 {
 #ifdef HAVE_CODESET  
   char *result = nl_langinfo (CODESET);
diff --git a/gutils.c b/gutils.c
index f09715ac2..3b6659841 100644
--- a/gutils.c
+++ b/gutils.c
@@ -761,8 +761,16 @@ g_int_hash (gconstpointer v)
   return *(const gint*) v;
 }
 
+/**
+ * g_get_codeset:
+ * 
+ * Get the codeset for the current locale.
+ * 
+ * Return value: a newly allocated string containing the name
+ * of the codeset. This string must be freed with g_free().
+ **/
 gchar *
-g_locale_get_codeset (void)
+g_get_codeset (void)
 {
 #ifdef HAVE_CODESET  
   char *result = nl_langinfo (CODESET);
-- 
2.34.1