The local 'reds' variable shadows the 'reds' function argument and it is the exact same instance. --- server/reds.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/server/reds.c b/server/reds.c index 60d8903..327711d 100644 --- a/server/reds.c +++ b/server/reds.c @@ -3238,11 +3238,8 @@ static int spice_server_char_device_add_interface(SpiceServer *reds, } if (dev_state) { - RedsState *reds; - spice_assert(char_device->st); - g_object_get(G_OBJECT(dev_state), "spice-server", &reds, NULL); g_object_weak_ref(G_OBJECT(dev_state), (GWeakNotify)reds_on_char_device_state_destroy, reds); -- 2.4.11 _______________________________________________ Spice-devel mailing list Spice-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/spice-devel