From fdbc9102c79c1a6d4134d5f5b8692658b2cf67ef Mon Sep 17 00:00:00 2001 From: Tomohiro Kusumi Date: Wed, 7 Jun 2017 23:18:48 +0300 Subject: [PATCH] use ARRAY_SIZE() for ignore_error_nr[etype] Signed-off-by: Tomohiro Kusumi Signed-off-by: Jens Axboe --- td_error.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/td_error.c b/td_error.c index 903f9ea5..9d58a314 100644 --- a/td_error.c +++ b/td_error.c @@ -20,8 +20,7 @@ int td_non_fatal_error(struct thread_data *td, enum error_type_bit etype, if (!td->o.ignore_error[etype]) { td->o.ignore_error[etype] = __NON_FATAL_ERR; - td->o.ignore_error_nr[etype] = sizeof(__NON_FATAL_ERR) - / sizeof(int); + td->o.ignore_error_nr[etype] = ARRAY_SIZE(__NON_FATAL_ERR); } if (!(td->o.continue_on_error & (1 << etype))) -- 2.25.1