Browse Source

1. when pat table changed in ts stream , Reconnect ts stream

wing_pn 7 years ago
parent
commit
5fa6a620ff
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      input.c

+ 2
- 2
input.c View File

182
 	// Process PAT
182
 	// Process PAT
183
 	s->pat = ts_pat_push_packet(s->pat, ts_packet);
183
 	s->pat = ts_pat_push_packet(s->pat, ts_packet);
184
 
184
 
185
-	s->last_pat = ts_pat_push_packet(s->last_pat, ts_packet);
185
+	
186
 	if (s->last_pat->initialized) {
186
 	if (s->last_pat->initialized) {
187
 		if (!ts_pat_is_same(s->pat, s->last_pat)) {
187
 		if (!ts_pat_is_same(s->pat, s->last_pat)) {
188
 			proxy_log(r, "PAT changed.");
188
 			proxy_log(r, "PAT changed.");
191
 		ts_pat_free(&s->last_pat);
191
 		ts_pat_free(&s->last_pat);
192
 		s->last_pat = ts_pat_alloc();
192
 		s->last_pat = ts_pat_alloc();
193
 	}
193
 	}
194
-
194
+    s->last_pat = ts_pat_push_packet(s->last_pat, ts_packet);
195
 	if (s->pat->initialized) {
195
 	if (s->pat->initialized) {
196
 		// PMT pid is still unknown
196
 		// PMT pid is still unknown
197
 		if (!s->pmt_pid) {
197
 		if (!s->pmt_pid) {

Loading…
Cancel
Save