1
0
Fork 0
forked from suyu/suyu

kernel/server_port: Simplify emptiness check within ShouldWait()

This commit is contained in:
Lioncash 2018-10-24 14:24:36 -04:00
parent b703aba622
commit 474bc29208

View file

@ -28,7 +28,7 @@ ResultVal<SharedPtr<ServerSession>> ServerPort::Accept() {
bool ServerPort::ShouldWait(Thread* thread) const {
// If there are no pending sessions, we wait until a new one is added.
return pending_sessions.size() == 0;
return pending_sessions.empty();
}
void ServerPort::Acquire(Thread* thread) {