GNOME Bugzilla – Bug 622017
[GstRtpMP4GDepay] Packet payload was too short.
Last modified: 2010-08-04 09:09:52 UTC
root@dm500hd:/etc/opkg# gst-launch rtspsrc location=rtsp://video3.americafree.tv/AFTVComedyH2641000.sdp debug=true Setting pipeline to PAUSED ... RTSP request message 0x7fd655c8 request line: method: 'OPTIONS' uri: 'rtsp://video3.americafree.tv/AFTVComedyH2641000.sdp' version: '1.0' headers: body: RTSP response message 0x7fd655e4 status line: code: '200' reason: 'OK' version: '1.0' headers: key: 'Server', value: 'QTSS/6.0.2 (Build/526.2; Platform/MacOSX; Release/Mac OS X Server; )' key: 'CSeq', value: '1' key: 'Public', value: 'DESCRIBE' key: 'Public', value: 'SETUP' key: 'Public', value: 'TEARDOWN' key: 'Public', value: 'PLAY' key: 'Public', value: 'PAUSE' key: 'Public', value: 'OPTIONS' key: 'Public', value: 'ANNOUNCE' key: 'Public', value: 'RECORD' body: length 0 RTSP request message 0x7fd655c8 request line: method: 'DESCRIBE' uri: 'rtsp://video3.americafree.tv/AFTVComedyH2641000.sdp' version: '1.0' headers: key: 'Accept', value: 'application/sdp' body: RTSP response message 0x7fd655e4 status line: code: '200' reason: 'OK' version: '1.0' headers: key: 'Server', value: 'QTSS/6.0.2 (Build/526.2; Platform/MacOSX; Release/Mac OS X Server; )' key: 'CSeq', value: '2' key: 'Cache-Control', value: 'no-cache' key: 'Content-Length', value: '798' key: 'Date', value: 'Fri, 18 Jun 2010 16:28:11 GMT' key: 'Expires', value: 'Fri, 18 Jun 2010 16:28:11 GMT' key: 'Content-Type', value: 'application/sdp' key: 'Content-Base', value: 'rtsp://video3.americafree.tv/AFTVComedyH2641000.sdp/' body: length 799 00000000 (0x482428): 76 3d 30 0d 0a 6f 3d 51 54 53 53 5f 50 6c 61 79 v=0..o=QTSS_Play 00000010 (0x482438): 5f 4c 69 73 74 20 31 30 37 37 30 38 34 39 30 35 _List 1077084905 00000020 (0x482448): 20 31 33 35 39 35 34 33 33 34 37 20 49 4e 20 49 1359543347 IN I 00000030 (0x482458): 50 34 20 36 33 2e 31 30 35 2e 31 32 32 2e 33 38 P4 63.105.122.38 00000040 (0x482468): 0d 0a 73 3d 41 46 54 56 43 6f 6d 65 64 79 48 32 ..s=AFTVComedyH2 00000050 (0x482478): 36 34 31 30 30 30 0d 0a 63 3d 49 4e 20 49 50 34 641000..c=IN IP4 00000060 (0x482488): 20 30 2e 30 2e 30 2e 30 0d 0a 62 3d 41 53 3a 31 0.0.0.0..b=AS:1 00000070 (0x482498): 30 30 35 0d 0a 74 3d 30 20 30 0d 0a 61 3d 78 2d 005..t=0 0..a=x- 00000080 (0x4824a8): 62 72 6f 61 64 63 61 73 74 63 6f 6e 74 72 6f 6c broadcastcontrol 00000090 (0x4824b8): 3a 52 54 53 50 0d 0a 61 3d 6d 61 78 70 72 61 74 :RTSP..a=maxprat 000000a0 (0x4824c8): 65 3a 31 31 33 2e 30 30 30 30 30 30 0d 0a 61 3d e:113.000000..a= 000000b0 (0x4824d8): 69 73 6d 61 2d 63 6f 6d 70 6c 69 61 6e 63 65 3a isma-compliance: 000000c0 (0x4824e8): 32 2c 32 2e 30 2c 32 0d 0a 61 3d 63 6f 6e 74 72 2,2.0,2..a=contr 000000d0 (0x4824f8): 6f 6c 3a 2a 0d 0a 6d 3d 76 69 64 65 6f 20 30 20 ol:*..m=video 0 000000e0 (0x482508): 52 54 50 2f 41 56 50 20 39 36 0d 0a 62 3d 41 53 RTP/AVP 96..b=AS 000000f0 (0x482518): 3a 39 30 36 0d 0a 62 3d 54 49 41 53 3a 38 38 31 :906..b=TIAS:881 00000100 (0x482528): 0d 0a 61 3d 33 47 50 50 2d 41 64 61 70 74 61 74 ..a=3GPP-Adaptat 00000110 (0x482538): 69 6f 6e 2d 53 75 70 70 6f 72 74 3a 31 0d 0a 61 ion-Support:1..a 00000120 (0x482548): 3d 6d 61 78 70 72 61 74 65 3a 31 31 33 0d 0a 61 =maxprate:113..a 00000130 (0x482558): 3d 72 74 70 6d 61 70 3a 39 36 20 48 32 36 34 2f =rtpmap:96 H264/ 00000140 (0x482568): 39 30 30 30 30 0d 0a 61 3d 63 6f 6e 74 72 6f 6c 90000..a=control 00000150 (0x482578): 3a 74 72 61 63 6b 49 44 3d 31 0d 0a 61 3d 63 6c :trackID=1..a=cl 00000160 (0x482588): 69 70 72 65 63 74 3a 30 2c 30 2c 35 37 36 2c 37 iprect:0,0,576,7 00000170 (0x482598): 36 38 0d 0a 61 3d 66 72 61 6d 65 73 69 7a 65 3a 68..a=framesize: 00000180 (0x4825a8): 39 36 20 37 36 38 2d 35 37 36 0d 0a 61 3d 66 6d 96 768-576..a=fm 00000190 (0x4825b8): 74 70 3a 39 36 20 70 61 63 6b 65 74 69 7a 61 74 tp:96 packetizat 000001a0 (0x4825c8): 69 6f 6e 2d 6d 6f 64 65 3d 31 3b 70 72 6f 66 69 ion-mode=1;profi 000001b0 (0x4825d8): 6c 65 2d 6c 65 76 65 6c 2d 69 64 3d 34 44 34 30 le-level-id=4D40 000001c0 (0x4825e8): 31 46 3b 73 70 72 6f 70 2d 70 61 72 61 6d 65 74 1F;sprop-paramet 000001d0 (0x4825f8): 65 72 2d 73 65 74 73 3d 4a 30 31 41 48 36 6b 59 er-sets=J01AH6kY 000001e0 (0x482608): 47 41 4a 4e 67 44 55 47 41 51 61 32 33 6f 44 65 GAJNgDUGAQa23oDe 000001f0 (0x482618): 41 70 6c 37 33 77 45 3d 2c 4b 4e 34 4a 79 41 3d Apl73wE=,KN4JyA= 00000200 (0x482628): 3d 0d 0a 61 3d 6d 70 65 67 34 2d 65 73 69 64 3a =..a=mpeg4-esid: 00000210 (0x482638): 32 30 31 0d 0a 6d 3d 61 75 64 69 6f 20 30 20 52 201..m=audio 0 R 00000220 (0x482648): 54 50 2f 41 56 50 20 39 37 0d 0a 62 3d 41 53 3a TP/AVP 97..b=AS: 00000230 (0x482658): 31 30 39 0d 0a 62 3d 54 49 41 53 3a 31 30 30 0d 109..b=TIAS:100. 00000240 (0x482668): 0a 61 3d 33 47 50 50 2d 41 64 61 70 74 61 74 69 .a=3GPP-Adaptati 00000250 (0x482678): 6f 6e 2d 53 75 70 70 6f 72 74 3a 31 0d 0a 61 3d on-Support:1..a= 00000260 (0x482688): 6d 61 78 70 72 61 74 65 3a 34 33 0d 0a 61 3d 72 maxprate:43..a=r 00000270 (0x482698): 74 70 6d 61 70 3a 39 37 20 6d 70 65 67 34 2d 67 tpmap:97 mpeg4-g 00000280 (0x4826a8): 65 6e 65 72 69 63 2f 34 34 31 30 30 2f 32 0d 0a eneric/44100/2.. 00000290 (0x4826b8): 61 3d 63 6f 6e 74 72 6f 6c 3a 74 72 61 63 6b 49 a=control:trackI 000002a0 (0x4826c8): 44 3d 32 0d 0a 61 3d 66 6d 74 70 3a 39 37 20 70 D=2..a=fmtp:97 p 000002b0 (0x4826d8): 72 6f 66 69 6c 65 2d 6c 65 76 65 6c 2d 69 64 3d rofile-level-id= 000002c0 (0x4826e8): 31 35 3b 6d 6f 64 65 3d 41 41 43 2d 68 62 72 3b 15;mode=AAC-hbr; 000002d0 (0x4826f8): 73 69 7a 65 6c 65 6e 67 74 68 3d 31 33 3b 69 6e sizelength=13;in 000002e0 (0x482708): 64 65 78 6c 65 6e 67 74 68 3d 33 3b 69 6e 64 65 dexlength=3;inde 000002f0 (0x482718): 78 64 65 6c 74 61 6c 65 6e 67 74 68 3d 33 3b 63 xdeltalength=3;c 00000300 (0x482728): 6f 6e 66 69 67 3d 31 32 31 30 0d 0a 61 3d 6d 70 onfig=1210..a=mp 00000310 (0x482738): 65 67 34 2d 65 73 69 64 3a 31 30 31 0d 0a 00 eg4-esid:101... sdp packet 0x7fd65600: version: '0' origin: username: 'QTSS_Play_List' sess_id: '1077084905' sess_version: '1359543347' nettype: 'IN' addrtype: 'IP4' addr: '63.105.122.38' session_name: 'AFTVComedyH2641000' information: '(NULL)' uri: '(NULL)' connection: nettype: 'IN' addrtype: 'IP4' address: '0.0.0.0' ttl: '0' addr_number: '0' bandwidths: type: 'AS' bandwidth: '1005' key: type: '(NULL)' data: '(NULL)' attributes: attribute 'x-broadcastcontrol' : 'RTSP' attribute 'maxprate' : '113.000000' attribute 'isma-compliance' : '2,2.0,2' attribute 'control' : '*' medias: media 0: media: 'video' port: '0' num_ports: '4294967295' proto: 'RTP/AVP' formats: format '96' information: '(NULL)' bandwidths: type: 'AS' bandwidth: '906' type: 'TIAS' bandwidth: '881' key: type: '(NULL)' data: '(NULL)' attributes: attribute '3GPP-Adaptation-Support' : '1' attribute 'maxprate' : '113' attribute 'rtpmap' : '96 H264/90000' attribute 'control' : 'trackID=1' attribute 'cliprect' : '0,0,576,768' attribute 'framesize' : '96 768-576' attribute 'fmtp' : '96 packetization-mode=1;profile-level-id=4D401F;sprop-parameter-sets=J01AH6kYGAJNgDUGAQa23oDeApl73wE=,KN4JyA==' attribute 'mpeg4-esid' : '201' media 1: media: 'audio' port: '0' num_ports: '4294967295' proto: 'RTP/AVP' formats: format '97' information: '(NULL)' bandwidths: type: 'AS' bandwidth: '109' type: 'TIAS' bandwidth: '100' key: type: '(NULL)' data: '(NULL)' attributes: attribute '3GPP-Adaptation-Support' : '1' attribute 'maxprate' : '43' attribute 'rtpmap' : '97 mpeg4-generic/44100/2' attribute 'control' : 'trackID=2' attribute 'fmtp' : '97 profile-level-id=15;mode=AAC-hbr;sizelength=13;indexlength=3;indexdeltalength=3;config=1210' attribute 'mpeg4-esid' : '101' ERROR: Pipeline doesn't want to pause. ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Could not get/set settings from/on resource. Additional debug info: gstrtspsrc.c(4750): gst_rtspsrc_setup_streams (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Could not setup transport. Setting pipeline to NULL ... Freeing pipeline ...
Created attachment 164022 [details] debug log GST_DEBUG=*:5 GST_DEBUG_NO_COLOR=1 gst-launch rtspsrc location=rtsp://video3.americafree.tv/AFTVComedyH2641000.sdp debug=true >bug622017_rtspsrc.log 2>&1
the problem derives from a missing gst-plugins-udp my request is to clarify the error message in this case
Created attachment 165358 [details] Debug log of "Packet payload was too short" error GST_DEBUG=*:5 GST_DEBUG_NO_COLOR=1 gst-launch-0.10 rtspsrc location=rtsp://ondemand.quicktime.zdf.newmedia.nacamar.net/zdf/data/quicktime/zdf/10/04/100401_1900_wet_vh.mp4 debug=True ! rtp mp4gdepay ! fakesink >bug622017_Packet_payload_was_too_short.log 2>&1
it seems as if the UDP ports for the seperate elementary streams were mutually switched since there are also packets that are actually larger than expected: 0:00:06.792806000 25973 0x4b2558 LOG basertpdepayload gstbasertpdepayload.c:309:gst_base_rtp_depayload_chain:<rtpmp4gdepay0> got packet 49993, expected 17793, gap -32200
Created attachment 165370 [details] [review] patch for udpsrc First patch to udpsrc to avoid port reuse
Created attachment 165371 [details] [review] patch for rtspsrc patch to avoid port reuse in rtspsrc
your patches fixed the issue. thanks once again, wim!
Please don't mark bugs as FIXED before the patches have been committed, thanks.
Comment on attachment 165370 [details] [review] patch for udpsrc >+ reuse = src->reuse ? 1 : 0; > if ((ret = > setsockopt (src->sock.fd, SOL_SOCKET, SO_REUSEADDR, &reuse, > sizeof (reuse))) < 0) Fwiw, on some systems (*BSD) there also seems to be a separate SO_REUSEPORT...
i've noticed that the patches haven't found their way into release 0.10.24 yet, hope they won't be forgotten!
commit 9dcfed0a5b0bf24cec0bcf13fc1a9e3c355522f1 Author: Wim Taymans <wim.taymans@collabora.co.uk> Date: Tue Jul 6 18:22:24 2010 +0200 rtspsrc: don't reuse udp sockets Don't reuse sockets but make the udpsrc element fail the state change when the socket is already in use. If we don't prevent reuse, we might end up using the same port for different streams in some cases. Fixes #622017