qemu-trivial
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-trivial] [PULL 14/17] async: use ARRAY_SIZE macro


From: Michael Tokarev
Subject: [Qemu-trivial] [PULL 14/17] async: use ARRAY_SIZE macro
Date: Sat, 10 Feb 2018 10:55:09 +0300

From: Philippe Mathieu-Daudé <address@hidden>

Applied using the Coccinelle semantic patch scripts/coccinelle/use_osdep.cocci

Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
Signed-off-by: Michael Tokarev <address@hidden>
Reviewed-by: Marc-André Lureau <address@hidden>
---
 util/aio-posix.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/util/aio-posix.c b/util/aio-posix.c
index 1427f49b4a..d8f0cb4af8 100644
--- a/util/aio-posix.c
+++ b/util/aio-posix.c
@@ -119,7 +119,7 @@ static int aio_epoll(AioContext *ctx, GPollFD *pfds,
     }
     if (timeout <= 0 || ret > 0) {
         ret = epoll_wait(ctx->epollfd, events,
-                         sizeof(events) / sizeof(events[0]),
+                         ARRAY_SIZE(events),
                          timeout);
         if (ret <= 0) {
             goto out;
-- 
2.11.0




reply via email to

[Prev in Thread] Current Thread [Next in Thread]