Skip to content

Commit 2ba70a3

Browse files
committed
Merge branch 'rs/gc-sort-func-cast-fix'
Fix broken sorting of maintenance tasks. * rs/gc-sort-func-cast-fix: gc: fix cast in compare_tasks_by_selection()
2 parents 57228d3 + a1c7479 commit 2ba70a3

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

builtin/gc.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1253,10 +1253,8 @@ static struct maintenance_task tasks[] = {
12531253

12541254
static int compare_tasks_by_selection(const void *a_, const void *b_)
12551255
{
1256-
const struct maintenance_task *a, *b;
1257-
1258-
a = (const struct maintenance_task *)&a_;
1259-
b = (const struct maintenance_task *)&b_;
1256+
const struct maintenance_task *a = a_;
1257+
const struct maintenance_task *b = b_;
12601258

12611259
return b->selected_order - a->selected_order;
12621260
}

0 commit comments

Comments
 (0)