aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorprasanth kamuju <prasanth.kamuju@linaro.org>2015-02-05 16:51:10 +0530
committerNicolas Dechesne <nicolas.dechesne@linaro.org>2015-03-02 16:09:30 +0000
commit2f9efbd9520acd1b6968fff027d3f3132cc07519 (patch)
tree1df9756746f6ac005ab6ac990771fdbf5776d944
parenta11eec5b50a21f350f462c3d5f611f6c17a81dbd (diff)
gstqcvideodec:FireFox crashed while playing youtube videos
Replace "return NULL" with "pthread_exit(NULL)" in video_thread. Video thread rewind is not happening properly when the video thread return with NULL. Because of it, stack smashing detected and not allowing subsequent videos to play. Signed-off-by: prasanth kamuju <prasanth.kamuju@linaro.org> Signed-off-by: Nicolas Dechesne <nicolas.dechesne@linaro.org>
-rw-r--r--src/gstqcvideodec.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gstqcvideodec.c b/src/gstqcvideodec.c
index 952526b..50290e0 100644
--- a/src/gstqcvideodec.c
+++ b/src/gstqcvideodec.c
@@ -1193,7 +1193,7 @@ video_thread (void *context)
if (decode_context == NULL) {
GST_ERROR ("video thread recieved NULL context");
- return NULL;
+ pthread_exit(NULL);
}
while (1) {
@@ -1345,7 +1345,7 @@ video_thread (void *context)
if (flow != GST_FLOW_OK) {
GST_ERROR
("gst_buffer_pool_acquire_buffer failed and GST_FLOW_Error ");
- return NULL;
+ pthread_exit(NULL);
}
gst_buffer_insert_memory (gst_local_buf, -1,
gst_dmabuf_allocator_alloc (derivedpool->allocator,
@@ -1372,7 +1372,7 @@ video_thread (void *context)
if (ioctl (decode_context->video_driver_fd,
VDEC_IOCTL_FILL_OUTPUT_BUFFER, &ioctl_msg) < 0) {
GST_ERROR ("Decoder frame failed");
- return NULL;
+ pthread_exit(NULL);
}
GST_VIDEO_DECODER_STREAM_UNLOCK (decoder_cxt);
break;
@@ -1398,7 +1398,7 @@ video_thread (void *context)
if (vdec_msg.msgcode == VDEC_MSG_RESP_STOP_DONE) {
GST_INFO ("Video_thread is going to close");
- return NULL;
+ pthread_exit(NULL);
}
}