mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-24 02:31:03 +00:00
nsf: Don't use GST_FLOW_IS_FATAL()
This commit is contained in:
parent
dd8ae4e027
commit
d95bb66074
2 changed files with 9 additions and 11 deletions
|
@ -341,16 +341,14 @@ pause:
|
|||
GST_DEBUG_OBJECT (nsfdec, "pausing task, reason %s", reason);
|
||||
gst_pad_pause_task (pad);
|
||||
|
||||
if (GST_FLOW_IS_FATAL (ret) || ret == GST_FLOW_NOT_LINKED) {
|
||||
if (ret == GST_FLOW_UNEXPECTED) {
|
||||
/* perform EOS logic, FIXME, segment seek? */
|
||||
gst_pad_push_event (pad, gst_event_new_eos ());
|
||||
} else {
|
||||
/* for fatal errors we post an error message */
|
||||
GST_ELEMENT_ERROR (nsfdec, STREAM, FAILED,
|
||||
(NULL), ("streaming task paused, reason %s", reason));
|
||||
gst_pad_push_event (pad, gst_event_new_eos ());
|
||||
}
|
||||
if (ret == GST_FLOW_UNEXPECTED) {
|
||||
/* perform EOS logic, FIXME, segment seek? */
|
||||
gst_pad_push_event (pad, gst_event_new_eos ());
|
||||
} else if (ret == GST_FLOW_NOT_LINKED || ret < GST_FLOW_UNEXPECTED) {
|
||||
/* for fatal errors we post an error message */
|
||||
GST_ELEMENT_ERROR (nsfdec, STREAM, FAILED,
|
||||
(NULL), ("streaming task paused, reason %s", reason));
|
||||
gst_pad_push_event (pad, gst_event_new_eos ());
|
||||
}
|
||||
goto done;
|
||||
}
|
||||
|
|
|
@ -164,7 +164,7 @@ apu_setchan (int chan, boolean enabled)
|
|||
}
|
||||
old = (apu->mix_enable >> chan) & 1;
|
||||
if (enabled != (boolean) - 1) {
|
||||
apu->mix_enable = (apu->mix_enable & ~(1 << chan)) | ((!!enabled) << chan);
|
||||
apu->mix_enable = (apu->mix_enable & ~(1 << chan)) | ((! !enabled) << chan);
|
||||
}
|
||||
return old;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue