Index: gobject/pygsource.c
===================================================================
--- gobject/pygsource.c	(revision 729)
+++ gobject/pygsource.c	(working copy)
@@ -110,14 +110,11 @@
 {
     CHECK_DESTROYED(self, NULL);
 
-    if (self->python_source && self->source->context) {
-	PyGRealSource *pysource = (PyGRealSource *)self->source;
-	Py_DECREF(pysource->obj);
-    }
-
     g_source_destroy(self->source);
-    self->source = NULL;
 
+    if (self->python_source)
+	g_source_unref(self->source);
+
     Py_INCREF(Py_None);
     return Py_None;
 }
@@ -369,8 +366,9 @@
     Py_XDECREF(tmp);
 
     if (self->source) {
-	g_source_unref(self->source);
+	GSource* source = self->source;
 	self->source = NULL;
+	g_source_unref(source);
     }
 
     return 0;
@@ -504,6 +502,7 @@
 pyg_source_finalize(GSource *source)
 {
     PyGRealSource *pysource = (PyGRealSource *)source;
+    PyGSource* self = pysource->obj;
     PyObject *func, *t;
     PyGILState_STATE state;
 
@@ -521,6 +520,11 @@
 	}
     }
 
+    if (self->source) {
+	self->source = NULL;
+	Py_DECREF(pysource->obj);
+    }
+
     pyg_gil_state_release(state);
 }
 
