We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HttpData.cpp 的 handleConn() 函数中:
loop_->runInLoop(bind(&HttpData::handleClose, shared_from_this()));
这里用 runinloop 真的有必要吗,因为这里loop_ 就是 HttpData 内指向本 eventloop 的指针,可以确定是在本线程(eventloop)执行的吧。所以跟直接调用 handleClose() 有什么区别?
The text was updated successfully, but these errors were encountered:
可以直接调的,用runInLoop的原因只是因为这样不用动脑,并且一定不会错,follow自己的风格就好了
Sorry, something went wrong.
No branches or pull requests
HttpData.cpp 的 handleConn() 函数中:
loop_->runInLoop(bind(&HttpData::handleClose, shared_from_this()));
这里用 runinloop 真的有必要吗,因为这里loop_ 就是 HttpData 内指向本 eventloop 的指针,可以确定是在本线程(eventloop)执行的吧。所以跟直接调用 handleClose() 有什么区别?
The text was updated successfully, but these errors were encountered: