Commit 75886ba6 authored by Robert Swain's avatar Robert Swain Committed by Tim-Philipp Müller

oss4: Address unused but set variables

GCC 4.6.x complains about such variable usage. Unused but set variables
were removed except that gst_oss4_mixer_slider_set_mute () now returns
the value from the call to gst_oss4_mixer_set_control_val ().
parent 098cf89e
......@@ -219,7 +219,7 @@ gst_oss4_mixer_slider_set_mute (GstOss4MixerSlider * s, gboolean mute)
}
ret = gst_oss4_mixer_set_control_val (s->mixer, s->mc, volume);
} else {
ret = gst_oss4_mixer_set_control_val (s->mixer, s->mc->mute, !!mute);
ret = gst_oss4_mixer_set_control_val (s->mixer, s->mc->mute, ! !mute);
}
if (mute) {
......@@ -228,7 +228,7 @@ gst_oss4_mixer_slider_set_mute (GstOss4MixerSlider * s, gboolean mute)
track->flags &= ~GST_MIXER_TRACK_MUTE;
}
return FALSE;
return ret;
}
GstMixerTrack *
......@@ -286,7 +286,7 @@ gst_oss4_mixer_slider_process_change_unlocked (GstMixerTrack * track)
if (s->mc->mute != NULL && s->mc->mute->changed) {
gst_mixer_mute_toggled (GST_MIXER (s->mixer), track,
!!s->mc->mute->last_val);
! !s->mc->mute->last_val);
} else {
/* nothing to do here, since we don't/can't easily implement the record
* flag */
......
......@@ -84,7 +84,6 @@ gboolean
gst_oss4_mixer_switch_get (GstOss4MixerSwitch * s, gboolean * disabled)
{
GstMixerTrack *track;
int flag;
int enabled = -1;
track = GST_MIXER_TRACK (s);
......@@ -95,8 +94,6 @@ gst_oss4_mixer_switch_get (GstOss4MixerSwitch * s, gboolean * disabled)
return FALSE;
}
flag = (enabled == 0) ? GST_MIXER_TRACK_MUTE : 0;
if (enabled) {
track->flags &= ~GST_MIXER_TRACK_MUTE;
} else {
......
......@@ -283,7 +283,6 @@ gst_oss4_property_probe_get_values (GstPropertyProbe * probe,
guint prop_id, const GParamSpec * pspec)
{
struct oss_sysinfo si = { {0,}, };
GstElementClass *klass;
GValueArray *array = NULL;
GstObject *obj;
GList *devices, *l;
......@@ -299,7 +298,6 @@ gst_oss4_property_probe_get_values (GstPropertyProbe * probe,
GST_OBJECT_LOCK (obj);
/* figure out whether the element is a source or sink */
klass = GST_ELEMENT_GET_CLASS (GST_ELEMENT (probe));
if (GST_IS_OSS4_SINK (probe)) {
GST_DEBUG_OBJECT (probe, "probing available output devices");
cap_mask = PCM_CAP_OUTPUT;
......
......@@ -121,15 +121,11 @@ static void
gst_oss4_source_class_init (GstOss4SourceClass * klass)
{
GObjectClass *gobject_class;
GstElementClass *gstelement_class;
GstBaseSrcClass *gstbasesrc_class;
GstBaseAudioSrcClass *gstbaseaudiosrc_class;
GstAudioSrcClass *gstaudiosrc_class;
gobject_class = (GObjectClass *) klass;
gstelement_class = (GstElementClass *) klass;
gstbasesrc_class = (GstBaseSrcClass *) klass;
gstbaseaudiosrc_class = (GstBaseAudioSrcClass *) klass;
gstaudiosrc_class = (GstAudioSrcClass *) klass;
gobject_class->dispose = gst_oss4_source_dispose;
......@@ -928,16 +924,12 @@ static void
gst_oss4_source_mixer_set_mute (GstMixer * mixer, GstMixerTrack * track,
gboolean mute)
{
GstOss4Source *oss;
g_return_if_fail (mixer != NULL);
g_return_if_fail (track != NULL);
g_return_if_fail (GST_IS_MIXER_TRACK (track));
g_return_if_fail (GST_IS_OSS4_SOURCE (mixer));
g_return_if_fail (GST_OSS4_SOURCE_IS_OPEN (mixer));
oss = GST_OSS4_SOURCE (mixer);
/* FIXME: implement gst_oss4_source_mixer_set_mute() - what to do here? */
/* oss4_mixer_set_mute (mixer->mixer, track, mute); */
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment