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 777224 - rtspsrc: unable to receive data using select-stream
rtspsrc: unable to receive data using select-stream
Status: RESOLVED DUPLICATE of bug 777101
Product: GStreamer
Classification: Platform
Component: gst-plugins-good
1.x
Other Linux
: Normal normal
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2017-01-13 16:35 UTC by Nicola
Modified: 2017-01-26 13:59 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
gstlogs (232.16 KB, text/plain)
2017-01-13 16:35 UTC, Nicola
  Details
wireshark capture (302.38 KB, application/x-pcapng)
2017-01-13 16:35 UTC, Nicola
  Details
proposed fix (912 bytes, patch)
2017-01-23 15:23 UTC, Nicola
committed Details | Review

Description Nicola 2017-01-13 16:35:27 UTC
Created attachment 343443 [details]
gstlogs

rtspsrc is unable to receive data in tcp mode if the rtsp server has multiple stream and an app setup only some streams using select-stream signal.

Please take a look at the attacched logs, the rtsp server has 3 media: audio,video and metadata

audio and metadata are disabled by signal and video is enabled, rtsp SETUP for video is correctly done but the received data is ignored. 

This use case works fine in udp mode and if no stream is disabled by signal, the problem happen only using rtsp over tcp if some medias are not selected and only with some rtsp server,

I have no time to do a proper investigation now but I suspect that the problem happen because the first declared media (audio) is disabled, for rtsp server that declare video (not disabled by signal) before audio works fine
Comment 1 Nicola 2017-01-13 16:35:55 UTC
Created attachment 343444 [details]
wireshark capture
Comment 2 Nicola 2017-01-23 15:17:52 UTC
what happen here is that when new data is received over tcp we have these streams:

audio (no setup done):

stream id 0 channelpad[0] (nil) channel[0] 0 setup 0

video (setup done):

stream id 1 channelpad[0] 0x2259b70 channel[0] 0 setup 1

metadata (no setup done):

stream id 2 channelpad[0] (nil) channel[0] 0 setup 0

find_stream_by_channel here:

https://cgit.freedesktop.org/gstreamer/gst-plugins-good/tree/gst/rtsp/gstrtspsrc.c#n4372

is called with channel 0 and it returns the audio stream that have no outpad,

a quick solution is to check if setup is done in find_stream_by_channel

since find_stream_by_channel is used only for rtsp over tcp should not break anything
Comment 3 Nicola 2017-01-23 15:23:58 UTC
Created attachment 344040 [details] [review]
proposed fix
Comment 4 Nicola 2017-01-26 13:38:15 UTC
this is the same bug reported here

https://bugzilla.gnome.org/show_bug.cgi?id=777101
Comment 5 Sebastian Dröge (slomo) 2017-01-26 13:59:10 UTC
Ah sorry, I missed this one and only saw the other one popping up in my mails.

*** This bug has been marked as a duplicate of bug 777101 ***