Fix a write to freed memory: Unlock the channel's mutex before unrefing
authorTor Lillqvist <tml@iki.fi>
Mon, 6 Dec 2004 23:43:43 +0000 (23:43 +0000)
committerTor Lillqvist <tml@src.gnome.org>
Mon, 6 Dec 2004 23:43:43 +0000 (23:43 +0000)
2004-12-06  Tor Lillqvist  <tml@iki.fi>

* glib/giowin32.c (g_io_win32_finalize): Fix a write to freed
memory: Unlock the channel's mutex before unrefing the channel.

ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-12
ChangeLog.pre-2-6
ChangeLog.pre-2-8
glib/giowin32.c

index 72e7dfd..59ab5ae 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2004-12-06  Tor Lillqvist  <tml@iki.fi>
+
+       * glib/giowin32.c (g_io_win32_finalize): Fix a write to freed
+       memory: Unlock the channel's mutex before unrefing the channel.
+
 2004-12-06  Matthias Clasen  <mclasen@redhat.com>
 
        * configure.in: Remove a no longer needed hack for 
index 72e7dfd..59ab5ae 100644 (file)
@@ -1,3 +1,8 @@
+2004-12-06  Tor Lillqvist  <tml@iki.fi>
+
+       * glib/giowin32.c (g_io_win32_finalize): Fix a write to freed
+       memory: Unlock the channel's mutex before unrefing the channel.
+
 2004-12-06  Matthias Clasen  <mclasen@redhat.com>
 
        * configure.in: Remove a no longer needed hack for 
index 72e7dfd..59ab5ae 100644 (file)
@@ -1,3 +1,8 @@
+2004-12-06  Tor Lillqvist  <tml@iki.fi>
+
+       * glib/giowin32.c (g_io_win32_finalize): Fix a write to freed
+       memory: Unlock the channel's mutex before unrefing the channel.
+
 2004-12-06  Matthias Clasen  <mclasen@redhat.com>
 
        * configure.in: Remove a no longer needed hack for 
index 72e7dfd..59ab5ae 100644 (file)
@@ -1,3 +1,8 @@
+2004-12-06  Tor Lillqvist  <tml@iki.fi>
+
+       * glib/giowin32.c (g_io_win32_finalize): Fix a write to freed
+       memory: Unlock the channel's mutex before unrefing the channel.
+
 2004-12-06  Matthias Clasen  <mclasen@redhat.com>
 
        * configure.in: Remove a no longer needed hack for 
index 72e7dfd..59ab5ae 100644 (file)
@@ -1,3 +1,8 @@
+2004-12-06  Tor Lillqvist  <tml@iki.fi>
+
+       * glib/giowin32.c (g_io_win32_finalize): Fix a write to freed
+       memory: Unlock the channel's mutex before unrefing the channel.
+
 2004-12-06  Matthias Clasen  <mclasen@redhat.com>
 
        * configure.in: Remove a no longer needed hack for 
index 9bffc05..72fe44e 100644 (file)
@@ -737,8 +737,8 @@ g_io_win32_finalize (GSource *source)
     send (channel->reset_send, send_buffer, sizeof (send_buffer), 0);
   }
 
-  g_io_channel_unref (watch->channel);
   UNLOCK (channel->mutex);
+  g_io_channel_unref (watch->channel);
 }
 
 GSourceFuncs g_io_watch_funcs = {