After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 762013 - curlhttpsink: Problem in curlhttpsink when qtmux uses faststart, don't send empty buffers
curlhttpsink: Problem in curlhttpsink when qtmux uses faststart, don't send e...
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
git master
Other Linux
: Normal normal
: 1.6.4
Assigned To: GStreamer Maintainers
GStreamer Maintainers
1.6.4
Depends on:
Blocks:
 
 
Reported: 2016-02-13 23:59 UTC by David Fernandez
Modified: 2016-04-14 17:43 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
gstcurlbasesink: Avoid start if the length of the buffer data (917 bytes, patch)
2016-02-13 23:59 UTC, David Fernandez
none Details | Review
gstcurlbasesink: Avoid start if the length of the buffer data (894 bytes, patch)
2016-02-16 14:14 UTC, David Fernandez
committed Details | Review

Description David Fernandez 2016-02-13 23:59:33 UTC
Created attachment 321089 [details] [review]
gstcurlbasesink: Avoid start if the length of the buffer data

Hi,

I have detected that when I use curlhttpsink after a qtmux with faststart the sink doesn't work fine. 

The sink receives a first empty buffer and it doesn't receive more buffers until the end of the video. However, the sink starts to send empty http requests with the first buffer and the sending never works fine.

I attach a patch that resolves the problem this avoiding empty buffers.

You can check the bug with this simple pipeline:
gst-launch-1.5 videotestsrc num-buffers=1000! x264enc ! qtmux faststart=TRUE ! curlhttpsink location=http://127.0.0.1:8080/

If you put a http-server you will be able to detect empty packages since the begining of the execution and the execution never ends. With my patch, this doesn't occur.

Thank you.
David.
Comment 1 David Fernandez 2016-02-16 14:14:20 UTC
Created attachment 321378 [details] [review]
gstcurlbasesink: Avoid start if the length of the buffer data

I forgot unmap the buffer.
Comment 2 Tim-Philipp Müller 2016-02-17 12:00:54 UTC
Makes sense I think. I have modified your patch slightly to move the GST_OBJECT_LOCK after the check, which avoids the need to unlock in your if branch.

 commit 55ba6f1ee898a9acc1bbac8dd3c53885eb9fe285
 Author: David Fernandez <d.fernandezlop@gmail.com>
 Date:   Tue Feb 16 15:10:34 2016 +0100

    curlbasesink: don't send empty buffers
    
    Fixes problem in curlhttpsink when qtmux uses faststart.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=762013
Comment 3 David Fernandez 2016-02-17 12:03:16 UTC
Thanks for the change!! It is the better way!
Comment 4 Tim-Philipp Müller 2016-02-17 12:07:49 UTC
Comment on attachment 321378 [details] [review]
gstcurlbasesink: Avoid start if the length of the buffer data

Committed with minor changes.