Browse Source

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 <benjamin.gaignard@linaro.org>
Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
Benjamin Gaignard 8 years ago
parent
commit
8f14e26b63
1 changed files with 1 additions and 1 deletions
  1. 1 1
      tools/testing/selftests/timers/clocksource-switch.c

+ 1 - 1
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;