From 95d894fd965dd3c20c3d62f9d32dc3a89a459497 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim-Philipp=20M=C3=BCller?= Date: Wed, 2 Sep 2009 13:35:02 +0100 Subject: [PATCH] mpegsmux, mpegpsmux: fix unused variable warning with the debugging system in core disabled --- gst/mpegpsmux/mpegpsmux.c | 3 +-- gst/mpegtsmux/mpegtsmux.c | 3 +-- gst/mpegtsmux/mpegtsmux.h | 2 ++ 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/gst/mpegpsmux/mpegpsmux.c b/gst/mpegpsmux/mpegpsmux.c index da31f28a4f..59c19aa5bb 100644 --- a/gst/mpegpsmux/mpegpsmux.c +++ b/gst/mpegpsmux/mpegpsmux.c @@ -484,14 +484,13 @@ mpegpsmux_collected (GstCollectPads * pads, MpegPsMux * mux) if (best != NULL) { /* @*buf : the buffer to be processed */ GstBuffer *buf = best->queued_buf; - GstCollectData *c_data = (GstCollectData *) best; gint64 pts = -1; g_return_val_if_fail (buf != NULL, GST_FLOW_ERROR); GST_DEBUG_OBJECT (mux, "Chose stream from pad %" GST_PTR_FORMAT " for output (PID: 0x%04x)", - c_data->pad, best->stream_id); + best->collect.pad, best->stream_id); /* set timestamp */ if (GST_CLOCK_TIME_IS_VALID (best->cur_ts)) { diff --git a/gst/mpegtsmux/mpegtsmux.c b/gst/mpegtsmux/mpegtsmux.c index 4ad22e7458..d0d02fa5bf 100644 --- a/gst/mpegtsmux/mpegtsmux.c +++ b/gst/mpegtsmux/mpegtsmux.c @@ -630,11 +630,10 @@ mpegtsmux_collected (GstCollectPads * pads, MpegTsMux * mux) if (G_UNLIKELY (prog->pcr_stream == NULL)) { if (best) { - MpegTsPadData *ts_data = (MpegTsPadData *) best; /* Take the first data stream for the PCR */ GST_DEBUG_OBJECT (COLLECT_DATA_PAD (best), "Use stream (pid=%d) from pad as PCR for program (prog_id = %d)", - ts_data->pid, ts_data->prog_id); + MPEG_TS_PAD_DATA (best)->pid, MPEG_TS_PAD_DATA (best)->prog_id); /* Set the chosen PCR stream */ tsmux_program_set_pcr_stream (prog, best->stream); diff --git a/gst/mpegtsmux/mpegtsmux.h b/gst/mpegtsmux/mpegtsmux.h index 2ebb7251dc..81668ba891 100644 --- a/gst/mpegtsmux/mpegtsmux.h +++ b/gst/mpegtsmux/mpegtsmux.h @@ -126,6 +126,8 @@ struct MpegTsMuxClass { GstElementClass parent_class; }; +#define MPEG_TS_PAD_DATA(data) ((MpegTsPadData *)(data)) + struct MpegTsPadData { GstCollectData collect; /* Parent */