Remove noop check

Co-authored-by: Andrew Kelley <andrew@ziglang.org>
This commit is contained in:
Loris Cro 2020-09-25 23:21:20 +02:00 committed by GitHub
parent 8d01133bd0
commit dc01ef7388
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -416,7 +416,7 @@ pub const File = struct {
return windows.ReadFile(self.handle, buffer, null, self.intended_io_mode);
}
if (self.intended_io_mode == .blocking or !std.io.is_async) {
if (self.intended_io_mode == .blocking) {
return os.read(self.handle, buffer);
} else {
return std.event.Loop.instance.?.read(self.handle, buffer, self.capable_io_mode != self.intended_io_mode);