From 458e4ada59e45034ec79a3d4256ff0965d1ec083 Mon Sep 17 00:00:00 2001 From: Jan Schmidt Date: Thu, 6 Nov 2003 16:30:32 +0000 Subject: [PATCH] Fix a crash when unlinking Ghost pads which was included in the reversion of error changes. Original commit message from CVS: Fix a crash when unlinking Ghost pads which was included in the reversion of error changes. --- gst/gstpad.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/gst/gstpad.c b/gst/gstpad.c index b12c9b7efd..9966d7954f 100644 --- a/gst/gstpad.c +++ b/gst/gstpad.c @@ -862,11 +862,11 @@ gst_pad_unlink (GstPad *srcpad, g_return_if_fail ((GST_RPAD_DIRECTION (realsrc) == GST_PAD_SRC) && (GST_RPAD_DIRECTION (realsink) == GST_PAD_SINK)); - if (GST_RPAD_UNLINKFUNC (srcpad)) { - GST_RPAD_UNLINKFUNC (srcpad) (srcpad); + if (GST_RPAD_UNLINKFUNC (realsrc)) { + GST_RPAD_UNLINKFUNC (realsrc) (GST_PAD_CAST (realsrc)); } - if (GST_RPAD_UNLINKFUNC (sinkpad)) { - GST_RPAD_UNLINKFUNC (sinkpad) (sinkpad); + if (GST_RPAD_UNLINKFUNC (realsink)) { + GST_RPAD_UNLINKFUNC (realsink) (GST_PAD_CAST (realsink)); } /* get the schedulers before we unlink */