Skip to content

Commit

Permalink
build_step: Fix build step merging
Browse files Browse the repository at this point in the history
`step->unique` was never being set.
  • Loading branch information
obiwac committed Nov 16, 2024
1 parent 5cab6f3 commit 16fae15
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/build_step.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,11 @@ int add_build_step(uint64_t unique, char const* name, build_step_cb_t cb, void*

// Actually add new build step.

build_steps = realloc(build_steps, (build_step_count + 1) * sizeof *build_steps);
build_steps = realloc(build_steps, ++build_step_count * sizeof *build_steps);
assert(build_steps != NULL);
build_step_t* const step = &build_steps[build_step_count++];
build_step_t* const step = &build_steps[build_step_count - 1];

step->unique = unique;
step->name = name;
step->cb = cb;
step->data_count = 1;
Expand Down

0 comments on commit 16fae15

Please sign in to comment.