Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
Z
ZLMediaKit
概览
Overview
Details
Activity
Cycle Analytics
版本库
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
问题
0
Issues
0
列表
Board
标记
里程碑
合并请求
0
Merge Requests
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
Snippets
成员
Collapse sidebar
Close sidebar
活动
图像
聊天
创建新问题
作业
提交
Issue Boards
Open sidebar
张翔宇
ZLMediaKit
Commits
dea84861
Commit
dea84861
authored
Jun 22, 2022
by
xiongguangjie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
more detail printf for handshake
parent
90874b2b
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
9 行增加
和
6 行删除
+9
-6
srt/Packet.cpp
+2
-2
srt/Packet.hpp
+3
-3
srt/SrtTransport.cpp
+4
-1
没有找到文件。
srt/Packet.cpp
查看文件 @
dea84861
...
...
@@ -230,7 +230,7 @@ std::string HandshakePacket::dump(){
printer
<<
"flag:"
<<
(
int
)
f
<<
"
\r\n
"
;
printer
<<
"control_type:"
<<
(
int
)
control_type
<<
"
\r\n
"
;
printer
<<
"sub_type:"
<<
(
int
)
sub_type
<<
"
\r\n
"
;
printer
<<
"type_specific_info:"
<<
type_specific_info
[
0
]
<<
":"
<<
type_specific_info
[
1
]
<<
":"
<<
type_specific_info
[
2
]
<<
":"
<<
type_specific_info
[
3
]
<<
"
\r\n
"
;
printer
<<
"type_specific_info:"
<<
(
int
)
type_specific_info
[
0
]
<<
":"
<<
(
int
)
type_specific_info
[
1
]
<<
":"
<<
(
int
)
type_specific_info
[
2
]
<<
":"
<<
(
int
)
type_specific_info
[
3
]
<<
"
\r\n
"
;
printer
<<
"timestamp:"
<<
timestamp
<<
"
\r\n
"
;
printer
<<
"dst_socket_id:"
<<
dst_socket_id
<<
"
\r\n
"
;
...
...
@@ -245,7 +245,7 @@ std::string HandshakePacket::dump(){
printer
<<
"syn_cookie:"
<<
syn_cookie
<<
"
\r\n
"
;
printer
<<
"peer_ip_addr:"
;
for
(
size_t
i
=
0
;
i
<
sizeof
(
peer_ip_addr
);
++
i
){
printer
<<
peer_ip_addr
[
i
]
<<
":"
;
printer
<<
(
int
)
peer_ip_addr
[
i
]
<<
":"
;
}
printer
<<
"
\r\n
"
;
...
...
srt/Packet.hpp
查看文件 @
dea84861
...
...
@@ -118,9 +118,9 @@ public:
USERDEFINEDTYPE
=
0x7FFF
};
uint
32_t
sub_type
:
16
;
uint
32_t
control_type
:
15
;
uint
32_t
f
:
1
;
uint
16_t
sub_type
;
uint
16_t
control_type
;
uint
8_t
f
;
uint8_t
type_specific_info
[
4
];
uint32_t
timestamp
;
uint32_t
dst_socket_id
;
...
...
srt/SrtTransport.cpp
查看文件 @
dea84861
...
...
@@ -228,7 +228,10 @@ void SrtTransport::handleHandshakeConclusion(HandshakePacket &pkt, struct sockad
void
SrtTransport
::
handleHandshake
(
uint8_t
*
buf
,
int
len
,
struct
sockaddr_storage
*
addr
)
{
HandshakePacket
pkt
;
assert
(
pkt
.
loadFromData
(
buf
,
len
));
if
(
!
pkt
.
loadFromData
(
buf
,
len
)){
WarnL
<<
"is not vaild HandshakePacket"
;
return
;
}
if
(
pkt
.
handshake_type
==
HandshakePacket
::
HS_TYPE_INDUCTION
)
{
handleHandshakeInduction
(
pkt
,
addr
);
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论