diff options
author | Sebastian Dröge <sebastian.droege@collabora.co.uk> | 2010-08-26 23:39:06 +0200 |
---|---|---|
committer | Sebastian Dröge <sebastian.droege@collabora.co.uk> | 2010-08-27 16:59:09 +0200 |
commit | 2e6f80bf8120628be1f8a7d0181ba3999689a251 (patch) | |
tree | 7837f8e23419725708a58bbaca82207fda8d5d9c | |
parent | 2dfb0d2772eec352eac20656b7e12f626eb50c76 (diff) |
elements: Stop using GST_FLOW_IS_FATAL()
-rw-r--r-- | plugins/elements/gstmultiqueue.c | 2 | ||||
-rw-r--r-- | plugins/elements/gstqueue.c | 3 | ||||
-rw-r--r-- | plugins/elements/gstqueue2.c | 7 |
3 files changed, 5 insertions, 7 deletions
diff --git a/plugins/elements/gstmultiqueue.c b/plugins/elements/gstmultiqueue.c index b9fa663e7f..d9bbba9560 100644 --- a/plugins/elements/gstmultiqueue.c +++ b/plugins/elements/gstmultiqueue.c | |||
@@ -1123,7 +1123,7 @@ out_flushing: | |||
1123 | /* upstream needs to see fatal result ASAP to shut things down, | 1123 | /* upstream needs to see fatal result ASAP to shut things down, |
1124 | * but might be stuck in one of our other full queues; | 1124 | * but might be stuck in one of our other full queues; |
1125 | * so empty this one and trigger dynamic queue growth */ | 1125 | * so empty this one and trigger dynamic queue growth */ |
1126 | if (GST_FLOW_IS_FATAL (sq->srcresult)) { | 1126 | if (sq->srcresult <= GST_FLOW_UNEXPECTED) { |
1127 | gst_data_queue_flush (sq->queue); | 1127 | gst_data_queue_flush (sq->queue); |
1128 | single_queue_underrun_cb (sq->queue, sq); | 1128 | single_queue_underrun_cb (sq->queue, sq); |
1129 | } | 1129 | } |
diff --git a/plugins/elements/gstqueue.c b/plugins/elements/gstqueue.c index 0306b04902..34d08ed5ef 100644 --- a/plugins/elements/gstqueue.c +++ b/plugins/elements/gstqueue.c | |||
@@ -1234,8 +1234,7 @@ out_flushing: | |||
1234 | GST_QUEUE_MUTEX_UNLOCK (queue); | 1234 | GST_QUEUE_MUTEX_UNLOCK (queue); |
1235 | /* let app know about us giving up if upstream is not expected to do so */ | 1235 | /* let app know about us giving up if upstream is not expected to do so */ |
1236 | /* UNEXPECTED is already taken care of elsewhere */ | 1236 | /* UNEXPECTED is already taken care of elsewhere */ |
1237 | if (eos && (GST_FLOW_IS_FATAL (ret) || ret == GST_FLOW_NOT_LINKED) && | 1237 | if (eos && (ret == GST_FLOW_NOT_LINKED || ret < GST_FLOW_UNEXPECTED)) { |
1238 | (ret != GST_FLOW_UNEXPECTED)) { | ||
1239 | GST_ELEMENT_ERROR (queue, STREAM, FAILED, | 1238 | GST_ELEMENT_ERROR (queue, STREAM, FAILED, |
1240 | (_("Internal data flow error.")), | 1239 | (_("Internal data flow error.")), |
1241 | ("streaming task paused, reason %s (%d)", | 1240 | ("streaming task paused, reason %s (%d)", |
diff --git a/plugins/elements/gstqueue2.c b/plugins/elements/gstqueue2.c index c56f887cc0..bb09e5a0a2 100644 --- a/plugins/elements/gstqueue2.c +++ b/plugins/elements/gstqueue2.c | |||
@@ -2303,8 +2303,7 @@ out_flushing: | |||
2303 | GST_QUEUE2_MUTEX_UNLOCK (queue); | 2303 | GST_QUEUE2_MUTEX_UNLOCK (queue); |
2304 | /* let app know about us giving up if upstream is not expected to do so */ | 2304 | /* let app know about us giving up if upstream is not expected to do so */ |
2305 | /* UNEXPECTED is already taken care of elsewhere */ | 2305 | /* UNEXPECTED is already taken care of elsewhere */ |
2306 | if (eos && (GST_FLOW_IS_FATAL (ret) || ret == GST_FLOW_NOT_LINKED) && | 2306 | if (eos && (ret == GST_FLOW_NOT_LINKED || ret < GST_FLOW_UNEXPECTED)) { |
2307 | (ret != GST_FLOW_UNEXPECTED)) { | ||
2308 | GST_ELEMENT_ERROR (queue, STREAM, FAILED, | 2307 | GST_ELEMENT_ERROR (queue, STREAM, FAILED, |
2309 | (_("Internal data flow error.")), | 2308 | (_("Internal data flow error.")), |
2310 | ("streaming task paused, reason %s (%d)", | 2309 | ("streaming task paused, reason %s (%d)", |
@@ -2684,7 +2683,7 @@ gst_queue2_src_activate_pull (GstPad * pad, gboolean active) | |||
2684 | result = gst_queue2_open_temp_location_file (queue); | 2683 | result = gst_queue2_open_temp_location_file (queue); |
2685 | } else if (!queue->ring_buffer) { | 2684 | } else if (!queue->ring_buffer) { |
2686 | queue->ring_buffer = g_malloc (queue->ring_buffer_max_size); | 2685 | queue->ring_buffer = g_malloc (queue->ring_buffer_max_size); |
2687 | result = !!queue->ring_buffer; | 2686 | result = ! !queue->ring_buffer; |
2688 | } else { | 2687 | } else { |
2689 | result = TRUE; | 2688 | result = TRUE; |
2690 | } | 2689 | } |
@@ -2887,7 +2886,7 @@ gst_queue2_set_property (GObject * object, | |||
2887 | break; | 2886 | break; |
2888 | case PROP_RING_BUFFER_MAX_SIZE: | 2887 | case PROP_RING_BUFFER_MAX_SIZE: |
2889 | queue->ring_buffer_max_size = g_value_get_uint64 (value); | 2888 | queue->ring_buffer_max_size = g_value_get_uint64 (value); |
2890 | queue->use_ring_buffer = !!queue->ring_buffer_max_size; | 2889 | queue->use_ring_buffer = ! !queue->ring_buffer_max_size; |
2891 | break; | 2890 | break; |
2892 | default: | 2891 | default: |
2893 | G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); | 2892 | G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); |