# HG changeset patch # User Mike Ruprecht # Date 1248232265 0 # Node ID feb17f2b5b7a128c5e731d610e62feb2dff30991 # Parent 3fc434ac0c57e8b47d3eb9b0a80ea14df68d5992 Don't crash when there isn't a webcam connected. diff -r 3fc434ac0c57 -r feb17f2b5b7a libpurple/mediamanager.c --- a/libpurple/mediamanager.c Tue Jul 21 17:10:29 2009 +0000 +++ b/libpurple/mediamanager.c Wed Jul 22 03:11:05 2009 +0000 @@ -780,7 +780,8 @@ pad = gst_element_get_static_pad(queue, "sink"); peer = gst_pad_get_peer(pad); gst_object_unref(pad); - gst_element_release_request_pad(GST_ELEMENT_PARENT(peer), peer); + if (peer != NULL) + gst_element_release_request_pad(GST_ELEMENT_PARENT(peer), peer); gst_element_set_locked_state(queue, TRUE); gst_element_set_state(queue, GST_STATE_NULL); gst_bin_remove(GST_BIN(GST_ELEMENT_PARENT(queue)), queue);