mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
mpegts discard header is not 0x47
This commit is contained in:
parent
4fdf242e99
commit
548c918efb
3 changed files with 6 additions and 3 deletions
|
@ -188,7 +188,7 @@ void srt_handle::handle_push_data(SRT_SOCKSTATUS status, const std::string& subp
|
|||
close_push_conn(conn_fd);
|
||||
return;
|
||||
}
|
||||
srs_trace("srt read data len:%d", ret);
|
||||
|
||||
srt_conn_ptr->update_timestamp(srt_now_ms);
|
||||
|
||||
srt2rtmp::get_instance()->insert_data_message(data, ret, subpath);
|
||||
|
|
|
@ -165,7 +165,6 @@ void srt_server::srt_handle_connection(SRT_SOCKSTATUS status, SRTSOCKET input_fd
|
|||
}
|
||||
|
||||
void srt_server::srt_handle_data(SRT_SOCKSTATUS status, SRTSOCKET input_fd, const std::string& dscr) {
|
||||
srs_trace("status:%d, fd:%d, dscr:%s", status, input_fd, dscr.c_str());
|
||||
_handle_ptr->handle_srt_socket(status, input_fd);
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -296,7 +296,11 @@ int ts_demux::decode(SRT_DATA_MSG_PTR data_ptr, TS_DATA_CALLBACK_PTR callback)
|
|||
path = data_ptr->get_path();
|
||||
for (unsigned int index = 0; index < count; index++)
|
||||
{
|
||||
ret = decode_unit(data_ptr->get_data() + 188*index, path, callback);
|
||||
unsigned char* data = data_ptr->get_data() + 188*index;
|
||||
if (data[0] != 0x47) {
|
||||
continue;
|
||||
}
|
||||
ret = decode_unit(data, path, callback);
|
||||
if (ret < 0)
|
||||
{
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue