From: Benjamin Gaignard Date: Wed, 23 Aug 2017 16:07:05 +0000 (+0200) Subject: selftests/timers: make loop consistent with array size X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=8f14e26b63b1b6c7c681409e9db1bbf054e00b32;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git selftests/timers: make loop consistent with array size clocksource_list array is defined as char [10][30] so to initialise it we only have to iterate 10 times. Signed-off-by: Benjamin Gaignard Signed-off-by: Shuah Khan --- diff --git a/tools/testing/selftests/timers/clocksource-switch.c b/tools/testing/selftests/timers/clocksource-switch.c index 3ef214628067..bfc974b4572d 100644 --- a/tools/testing/selftests/timers/clocksource-switch.c +++ b/tools/testing/selftests/timers/clocksource-switch.c @@ -50,7 +50,7 @@ int get_clocksources(char list[][30]) close(fd); - for (i = 0; i < 30; i++) + for (i = 0; i < 10; i++) list[i][0] = '\0'; head = buf;