From 14bc162cb99a42ed3417c0356962d04e56015365 Mon Sep 17 00:00:00 2001 From: Cole Miller Date: Tue, 23 Apr 2024 16:46:00 +0100 Subject: [PATCH] Revert tolerance for EAGAIN when probing async I/O This reverts canonical/raft#485. Signed-off-by: Cole Miller --- src/raft/uv_fs.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/raft/uv_fs.c b/src/raft/uv_fs.c index b4bf42114..403e7069f 100644 --- a/src/raft/uv_fs.c +++ b/src/raft/uv_fs.c @@ -840,14 +840,6 @@ static int probeAsyncIO(int fd, size_t size, bool *ok, char *errmsg) * errors, since we allocated the file with posix_fallocate and * the block size is supposed to be correct. */ *ok = false; - if (event.res == -EAGAIN) { - /* If EAGAIN is encountered we assume the functionality - * is supported but this write would have blocked for - * some reason. UvWriter has a fallback mechanism to - * schedule writes on the thread pool in case the async - * write fails with EAGAIN, so this is safe. */ - *ok = true; - } } return 0;