coccinelle: make use of DIV_ROUND_UP() wherever appropriate

Let's use our macros where we can
This commit is contained in:
Lennart Poettering
2018-03-20 20:59:02 +01:00
parent 3ceae1bc14
commit be6b0c2165
9 changed files with 30 additions and 11 deletions
+1 -1
View File
@@ -130,7 +130,7 @@ static int show_menu(char **x, unsigned n_columns, unsigned width, unsigned perc
assert(n_columns > 0);
n = strv_length(x);
per_column = (n + n_columns - 1) / n_columns;
per_column = DIV_ROUND_UP(n, n_columns);
break_lines = lines();
if (break_lines > 2)