NativeFd: fix CHECKs
GitOrigin-RevId: bbbbad169513c4503eba1c7a98349c98b9e6ed1a
This commit is contained in:
parent
787e370002
commit
2b382567be
@ -26,7 +26,9 @@ namespace td {
|
||||
class FdSet {
|
||||
public:
|
||||
void on_create_fd(NativeFd::Fd fd) {
|
||||
CHECK(is_valid(fd));
|
||||
if (!is_valid(fd)) {
|
||||
return;
|
||||
}
|
||||
if (is_stdio(fd)) {
|
||||
return;
|
||||
}
|
||||
@ -52,7 +54,9 @@ class FdSet {
|
||||
}
|
||||
|
||||
void on_close_fd(NativeFd::Fd fd) {
|
||||
CHECK(is_valid(fd));
|
||||
if (!is_valid(fd)) {
|
||||
return;
|
||||
}
|
||||
if (is_stdio(fd)) {
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user