mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-03-21 13:30:53 +08:00
Refine: 优化tcp/udp服务器异常管理断开机制
This commit is contained in:
@@ -75,12 +75,7 @@ ssize_t HttpSession::onRecvHeader(const char *header,size_t len) {
|
||||
|
||||
//默认后面数据不是content而是header
|
||||
ssize_t content_len = 0;
|
||||
auto &fun = it->second;
|
||||
try {
|
||||
(this->*fun)(content_len);
|
||||
}catch (exception &ex){
|
||||
shutdown(SockException(Err_shutdown,ex.what()));
|
||||
}
|
||||
(this->*(it->second))(content_len);
|
||||
|
||||
//清空解析器节省内存
|
||||
_parser.Clear();
|
||||
|
||||
Reference in New Issue
Block a user