<div dir="ltr">Hi all,<div>I need to reopen this thread.</div><div>I eventually find out the problem could be related to a packet that arrive in the between of two interleaved frame:</div><div><br></div><div>From Wireshark I have:</div><div>
        
        
        


<p style="margin-bottom:0in">No.        Time                             SRC            DST           PROT  Len       Info</p>
<p style="margin-bottom:0in"><font size="2"><b>288425</b>   1313.322        192.168.214.116 192.168.214.218 TCP     70      Interleaved
channel 0x00, 596 bytes[Unreassembled Packet]   0.000</font></p>
<p style="margin-bottom:0in"><font size="2"><b>288426</b>   1313.323        192.168.214.116 192.168.214.218 RTSP    161     Reply:
RTSP/1.0 200 OK 0.001</font></p>
<p style="margin-bottom:0in"><font size="2"><b>288427</b>   1313.324        192.168.214.218 192.168.214.116 TCP     66      60654
> rsms [ACK] Seq=27020 Ack=168154409 Win=30336 Len=0
TSval=42296588 TSecr=16694218   0.000</font></p>
<p style="margin-bottom:0in"><font size="2"><b>288428</b>   1313.324        192.168.214.218 192.168.214.116 TCP     66      [TCP
Dup ACK 288427#1] 60654 > rsms [ACK] Seq=27020 Ack=168154409
Win=30336 Len=0 TSval=42296588 TSecr=16694218   0.000</font></p>
<p style="margin-bottom:0in"><font size="2"><b>288428</b>   1313.324        192.168.214.218 192.168.214.116 TCP     66      [TCP
Dup ACK 288427#1] 60654 > rsms [ACK] Seq=27020 Ack=168154409
Win=30336 Len=0 TSval=42296588 TSecr=16694218   0.000</font></p>
<p style="margin-bottom:0in"><font size="2"><b>288428</b>   1313.324        192.168.214.218 192.168.214.116 TCP     66      [TCP
Dup ACK 288427#1] 60654 > rsms [ACK] Seq=27020 Ack=168154409
Win=30336 Len=0 TSval=42296588 TSecr=16694218   0.000</font></p>
<p style="margin-bottom:0in"><font size="2"><b>288429</b>   1313.324        192.168.214.116 192.168.214.218 RTSP    <font color="#ff0000"><b>662</b></font>       Continuation    0.000</font></p><p style="margin-bottom:0in">as  can be seen in the sequence above
the Reply  packet 288426 is arrived between packet 288425 and 288429
and has been interpreted as raw binary data.</p><p style="margin-bottom:0in"><br>
</p><p style="margin-bottom:0in">Here is the details of packet 288425:</p><p style="margin-bottom:0in"><br>
</p><p style="margin-bottom:0in">0000  08 00 27 63 29 12 00 11  14 12 09
d8 08 00 45 00   ..'c)... ......E. 
</p><p style="margin-bottom:0in">0010  00 38 17 d5 40 00 40 06  f4 4a c0
a8 d6 74 c0 a8   .8..@.@. .J...t.. 
</p><p style="margin-bottom:0in">0020  d6 da 27 d9 ec ee b0 1d  22 84 e5
9e 34 a8 80 10   ..'..... "...4... 
</p><p style="margin-bottom:0in">0030  1c 48 df 72 00 00 01 01  08 0a 00
fe bb ca 02 85   .H.r.... ........ 
</p><p style="margin-bottom:0in">0040  65 0b <b>24 00 02 54</b>         
                        e.$..T 
</p><p style="margin-bottom:0in;font-weight:normal"><br>
</p><p style="margin-bottom:0in;font-weight:normal">As can be seen
above, at 66 byte offset ( ETH=14 IP=20 TCP=34) there is the
Interleaved header saying that it will follow 0x0254=596 byte of raw
data. RawDataSize=596.</p><p style="margin-bottom:0in;font-weight:normal">And as a matter of
fact packet 288429 is 662-66=596 bytes, but in the middle  arrived
packet 288426 and Gstreamer  considered it as raw data 161-66=95
bytes. ReplyMessageSize = 95</p><p style="margin-bottom:0in;font-weight:normal"><br>
</p><p style="margin-bottom:0in;font-weight:normal">If I stop the
debugger on the error and I print builder->buffer  in the build_next() function in gstrtspconnection.c I get:</p><p style="margin-bottom:0in;font-weight:normal"><br>
</p><p style="margin-bottom:0in">(gdb) p/x builder->buffer[0] 
</p><p style="margin-bottom:0in">$39 = 0xdd 
</p><p style="margin-bottom:0in">(gdb) p/x builder->buffer[1] 
</p><p style="margin-bottom:0in">$40 = 0xbc 
</p><p style="margin-bottom:0in">(gdb) p/x builder->buffer[2] 
</p><p style="margin-bottom:0in">$41 = 0x41 
</p><p style="margin-bottom:0in">(gdb) p/x builder->buffer[3] 
</p><p style="margin-bottom:0in">$42 = 0xfb 
</p><p style="margin-bottom:0in">(gdb) p/x builder->buffer[4] 
</p><p style="margin-bottom:0in">$43 = 0x8a 
</p><p style="margin-bottom:0in"><br>
</p><p style="margin-bottom:0in">and if I inspect data of packet 288429:</p><p style="margin-bottom:0in"><br>
</p><p style="margin-bottom:0in">     80 e0 25 1e 19 20  fa 38 80 00 59
64 1c 41   e...%..  .8..Yd.A 
</p><p style="margin-bottom:0in">0050  91 d3 b7 a5 97 92 24 27  81 49 8f
8c a3 ce 97 47   ......$' .I.....G 
</p><p style="margin-bottom:0in">0060  de 19 a3 a1 43 01 7d 6c  68 f7 2e
45 ee 7b 78 c0   ....C.}l h..E.{x. 
</p><p style="margin-bottom:0in">0070  eb 31 c9 2c 62 ac 3c 81  f8 64 49
7d fd f0 c6 9e   .1.,b.<. .dI}.... 
</p><p style="margin-bottom:0in">0080  9b 67 13 64 1e f4 70 95  96 cb 08
d0 b8 8a 63 0f   .g.d..p. ......c. 
</p><p style="margin-bottom:0in">0090  7b b0 82 3b 6c f7 2b d3  a1 5f 1f
b2 ed 2d a0 e9   {..;l.+. ._...-.. 
</p><p style="margin-bottom:0in">00a0  ed c4 e4 de 27 9b 28 97  25 0e 7c
e3 6a 68 5b 4f   ....'.(. %.|.jh[O 
</p><p style="margin-bottom:0in">00b0  72 eb 09 6d cb e9 3b 5c  79 bc ef
cb 58 24 2f e6   r..m..;\ y...X$/. 
</p><p style="margin-bottom:0in">00c0  e2 e9 7f ff ce b9 33 db  c0 56 7d
7c 78 94 c4 54   ......3. .V}|x..T 
</p><p style="margin-bottom:0in">00d0  a6 32 7d b4 9e 09 bc 95  42 b2 c1
5f aa 23 db ac   .2}..... B.._.#.. 
</p><p style="margin-bottom:0in">00e0  7b cd 83 c1 54 8a 11 0a  56 ad 67
f9 5f b4 e7 e5   {...T... V.g._... 
</p><p style="margin-bottom:0in">00f0  0e 1b ba 7b b6 2c fb 63  36 73 85
23 a6 02 86 34   ...{.,.c 6s.#...4 
</p><p style="margin-bottom:0in">0100  0f 97 74 74 87 39 43 d7  2e 76 3d
2d 41 a5 87 f6   ..tt.9C. .v=-A... 
</p><p style="margin-bottom:0in">0110  a5 fc c4 32 79 90 61 52  f5 fd 90
af 21 11 19 1c   ...2y.aR ....!... 
</p><p style="margin-bottom:0in">0120  ec 3b 80 ce 39 ee d2 6a  f9 0a 0c
9c f8 66 ee d4   .;..9..j .....f.. 
</p><p style="margin-bottom:0in">0130  5f 5e 81 79 43 54 f1 18  b0 16 49
71 90 a6 5d e8   _^.yCT.. ..Iq..]. 
</p><p style="margin-bottom:0in">0140  57 93 d5 ce 06 67 f9 fd  c2 ea 0c
61 e3 6c fb 4d   W....g.. ...a.l.M 
</p><p style="margin-bottom:0in">0150  e5 ea e1 92 58 3e 7e 4b  74 6d 9c
f5 49 3b 64 8e   ....X>~K tm..I;d. 
</p><p style="margin-bottom:0in">0160  82 7f 3b a6 7f 9e 1b c8  49 71 bf
30 12 f5 f9 67   ..;..... Iq.0...g 
</p><p style="margin-bottom:0in">0170  53 74 fa 08 c6 70 2a 9f  fb 1e aa
a0 95 87 c9 d1   St...p*. ........ 
</p><p style="margin-bottom:0in">0180  79 0e 75 90 bf d5 1e d9  ec ce 68
b6 92 de d5 3a   y.u..... ..h....: 
</p><p style="margin-bottom:0in">0190  1b dd 67 a9 2c f8 be 23  79 5c 1d
d0 d0 22 6c 0e   ..g.,..# y\..."l. 
</p><p style="margin-bottom:0in">01a0  52 f5 cf a7 d2 b0 74 32  8b 88 cb
ce 58 52 05 b0   R.....t2 ....XR.. 
</p><p style="margin-bottom:0in">01b0  10 37 70 77 85 01 32 0b  00 90 64
46 5b 1a fc 3c   .7pw..2. ..dF[..< 
</p><p style="margin-bottom:0in">01c0  31 1f 12 98 9c 3e 3c a6  90 23 57
cc be 4b ab f0   1....><. .#W..K.. 
</p><p style="margin-bottom:0in">01d0  5b 2d 5e 06 5a 7d fb bb  1e 42 44
8e a9 82 4b f2   [-^.Z}.. .BD...K. 
</p><p style="margin-bottom:0in">01e0  7b 74 b9 cc 5a 97 54 2a  d2 ac c5
7e 52 b7 5f 65   {t..Z.T* ...~R._e 
</p><p style="margin-bottom:0in">01f0  da ce 4d 2c 25 77 b9 4c  e1 32 b6
7f 49 cd 48 ba   ..M,%w.L .2..I.H. 
</p><p style="margin-bottom:0in">0200  db b9 ed ab e5 09 04 24  9b 5c 4d
eb 10 7f 20 ab   .......$ .\M... . 
</p><p style="margin-bottom:0in">0210  b6 ce 9c 95 59 88 82 d3  71 4b 22
40 09 f9 c5 e4   ....Y... qK"@.... 
</p><p style="margin-bottom:0in">0220  6a f5 12 0b 03 a7 bc 62  b1 26 4e
84 af ed e8 3a   j......b .&N....: 
</p><p style="margin-bottom:0in">0230  17 dd 4e 3a 9b d0 cd <b>dd  bc 41
fb 8a</b> 6f 64 a8 b0   ..N:.... .A..od.. 
</p><p style="margin-bottom:0in">0240  f8 4f a1 c8 1c 01 33 c0  8b f1 09
6b a3 98 47 3b   .O....3. ...k..G; 
</p><p style="margin-bottom:0in">0250  fd d2 6d dc a7 78 ea d0  c8 3b 9e
06 26 57 75 51   ..m..x.. .;..&WuQ 
</p><p style="margin-bottom:0in">0260  7a b2 20 2c 86 4e 40 aa  47 d6 ef
5e cb 50 66 0a   z. ,.N@. G..^.Pf. 
</p><p style="margin-bottom:0in">0270  6b 0d ee 67 74 7d 93 50  52 e3 00
7b 7b aa c3 4d   k..gt}.P R..{{..M 
</p><p style="margin-bottom:0in">0280  25 de 53 ff db 04 81 33  42 9d 20
37 66 12 8b 33   %.S....3 B. 7f..3 
</p><p style="margin-bottom:0in">0290  41 e9 7d fb 98 1d                
                                 A.}...</p><p style="margin-bottom:0in">
        
        
        





































































</p><p style="margin-bottom:0in">at offset 501 (RawDataSize
- ReplyMessageSize:
596-95 ) I find the new data that the parser function is erroneously
processing.</p><p style="margin-bottom:0in">How can I handle such a kind of error? </p><p style="margin-bottom:0in">Eventually rtspsrc reports an GST_RTSP_EPARSE that in gst_rtspsrc_loop_interleaved is considered as an error and stops the pipeline.</p><p style="margin-bottom:0in">Any idea how to synchronize the stream?</p><p style="margin-bottom:0in">Many thanks in advance.</p><p style="margin-bottom:0in"> </p><p style="margin-bottom:0in"><br></p></div></div>