const correctness fixes, found by Arjan van de Ven and gcc.
authorMatthias Clasen <mclasen@redhat.com>
Thu, 17 Nov 2005 13:17:22 +0000 (13:17 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Thu, 17 Nov 2005 13:17:22 +0000 (13:17 +0000)
2005-11-17  Matthias Clasen  <mclasen@redhat.com>

* glib/gbacktrace.c:
* glib/gdate.c:
* glib/gthread.c: const correctness fixes, found
by Arjan van de Ven and gcc.

ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-12
glib/gbacktrace.c
glib/gdate.c
glib/gthread.c
gobject/ChangeLog
gobject/glib-genmarshal.c

index 6da35d6..c6e93d6 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2005-11-17  Matthias Clasen  <mclasen@redhat.com>
+
+       * glib/gbacktrace.c:
+       * glib/gdate.c:
+       * glib/gthread.c: const correctness fixes, found
+       by Arjan van de Ven and gcc.
+       
 2005-11-16  Behdad Esfahbod  <behdad@gnome.org>
 
        * docs/reference/glib/tmpl/unicode.sgml: Correct typo on mentioning
index 6da35d6..c6e93d6 100644 (file)
@@ -1,3 +1,10 @@
+2005-11-17  Matthias Clasen  <mclasen@redhat.com>
+
+       * glib/gbacktrace.c:
+       * glib/gdate.c:
+       * glib/gthread.c: const correctness fixes, found
+       by Arjan van de Ven and gcc.
+       
 2005-11-16  Behdad Esfahbod  <behdad@gnome.org>
 
        * docs/reference/glib/tmpl/unicode.sgml: Correct typo on mentioning
index 6da35d6..c6e93d6 100644 (file)
@@ -1,3 +1,10 @@
+2005-11-17  Matthias Clasen  <mclasen@redhat.com>
+
+       * glib/gbacktrace.c:
+       * glib/gdate.c:
+       * glib/gthread.c: const correctness fixes, found
+       by Arjan van de Ven and gcc.
+       
 2005-11-16  Behdad Esfahbod  <behdad@gnome.org>
 
        * docs/reference/glib/tmpl/unicode.sgml: Correct typo on mentioning
index 76bb5aa..5597b12 100644 (file)
@@ -92,9 +92,9 @@ void
 g_on_error_query (const gchar *prg_name)
 {
 #ifndef G_OS_WIN32
-  static const gchar *query1 = "[E]xit, [H]alt";
-  static const gchar *query2 = ", show [S]tack trace";
-  static const gchar *query3 = " or [P]roceed";
+  static const gchar * const query1 = "[E]xit, [H]alt";
+  static const gchar * const query2 = ", show [S]tack trace";
+  static const gchar * const query3 = " or [P]roceed";
   gchar buf[16];
 
   if (!prg_name)
index 85c6171..3e9db33 100644 (file)
@@ -473,7 +473,7 @@ static GDateDMY dmy_order[3] =
  * are counted as in the year 1900.  
  */
 
-static GDateYear twodigit_start_year = 1930;
+static const GDateYear twodigit_start_year = 1930;
 
 /* It is impossible to enter a year between 1 AD and 99 AD with this
  * in effect.  
index d39faa2..ee2dcbc 100644 (file)
@@ -201,7 +201,7 @@ g_once_impl (GOnce       *once,
 void 
 g_static_mutex_init (GStaticMutex *mutex)
 {
-  static GStaticMutex init_mutex = G_STATIC_MUTEX_INIT;
+  static const GStaticMutex init_mutex = G_STATIC_MUTEX_INIT;
 
   g_return_if_fail (mutex);
 
@@ -255,7 +255,7 @@ g_static_mutex_free (GStaticMutex* mutex)
 void     
 g_static_rec_mutex_init (GStaticRecMutex *mutex)
 {
-  static GStaticRecMutex init_mutex = G_STATIC_REC_MUTEX_INIT;
+  static const GStaticRecMutex init_mutex = G_STATIC_REC_MUTEX_INIT;
   
   g_return_if_fail (mutex);
 
@@ -723,7 +723,7 @@ g_thread_self (void)
 void
 g_static_rw_lock_init (GStaticRWLock* lock)
 {
-  static GStaticRWLock init_lock = G_STATIC_RW_LOCK_INIT;
+  static const GStaticRWLock init_lock = G_STATIC_RW_LOCK_INIT;
 
   g_return_if_fail (lock);
 
index a35641a..fb3932c 100644 (file)
@@ -1,3 +1,8 @@
+2005-11-17  Matthias Clasen  <mclasen@redhat.com>
+
+       * glib-genmarshal.c: const correctness fixes, found
+       by Arjan van de Ven and gcc.
+       
 Tue Nov  1 17:07:43 2005  Tim Janik  <timj@imendio.com>
 
        * gsignal.c: allocate signal handlers and handler match structures
index 1c4a4b0..1403fb8 100644 (file)
@@ -115,7 +115,7 @@ static GScannerConfig scanner_config_template =
   FALSE                 /* symbol_2_token */,
   FALSE                 /* scope_0_fallback */,
 };
-static gchar           *std_marshaller_prefix = "g_cclosure_marshal";
+static gchar           * const std_marshaller_prefix = "g_cclosure_marshal";
 static gchar           *marshaller_prefix = "g_cclosure_user_marshal";
 static GHashTable      *marshallers = NULL;
 static gboolean                 gen_cheader = FALSE;