e72d9a6ee1d138eae33800a029d4ff835bc05e83
diff --git a/gi/pygi-closure.c b/gi/pygi-closure.c
index a8f67e2..b3068ed 100644
--- a/gi/pygi-closure.c
+++ b/gi/pygi-closure.c
@@ -166,6 +166,7 @@ void _pygi_invoke_closure_free(gpointer data)
     
 
     Py_DECREF(invoke_closure->function);
+    Py_XDECREF(invoke_closure->user_data);
 
     g_callable_info_free_closure(invoke_closure->info,
                                  invoke_closure->closure);
diff --git a/tests/test_everything.py b/tests/test_everything.py
index ecdbd9f..411c1fd 100644
--- a/tests/test_everything.py
+++ b/tests/test_everything.py
@@ -5,6 +5,7 @@ import unittest
 
 import sys
 sys.path.insert(0, "../")
+from sys import getrefcount
 
 import gobject
 import cairo
@@ -159,6 +160,23 @@ class TestCallbacks(unittest.TestCase):
             
         self.assertEquals(TestCallbacks.called, 100)
 
+    def testCallbackUserdataRefCount(self):
+        TestCallbacks.called = False
+        def callback(userdata):
+            TestCallbacks.called = True
+            return 1
+
+        ud = "Test User Data"
+
+        start_ref_count = getrefcount(ud)
+        for i in range(100):
+            Everything.test_callback_destroy_notify(callback, ud)
+
+        Everything.test_callback_thaw_notifications()
+        end_ref_count = getrefcount(ud)
+
+        self.assertEquals(start_ref_count, end_ref_count)
+
     def testAsyncReadyCallback(self):
         TestCallbacks.called = False
         TestCallbacks.main_loop = gobject.MainLoop()
