Skip to content

Commit

Permalink
another try
Browse files Browse the repository at this point in the history
  • Loading branch information
TheGAzed committed Jun 23, 2024
1 parent 2a6a216 commit 20a6d4d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions program/source/structures/concrete/board.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ ksize_t _empty_cell_count(KGrid from);

Kakuro init_kakuro(FILE * kakuro_file) {
assert(kakuro_file && "KAKURO FILE POINTER IS NULL");
rewind(kakuro_file);

Kakuro k = { 0 };
_kakuro_alloc(&k, kakuro_file);
Expand Down Expand Up @@ -104,8 +105,6 @@ KGrid _init_grid(FILE * kakuro_file) {
assert(fread(&(g.size[ROW]), sizeof(ksize_t), 1, kakuro_file));
assert(fread(&(g.size[COLUMN]), sizeof(ksize_t), 1, kakuro_file));

assert(g.size[ROW] && "ROW COUNT IS ZERO");
assert(g.size[COLUMN] && "COLUMN COUNT IS ZERO");
g.count = g.size[ROW] * g.size[COLUMN];

assert((g.grids[ROW] = malloc(g.size[ROW] * sizeof(lookup_t*))) && "ALLOCATION TO ROW ARRAY FAILED");
Expand Down

0 comments on commit 20a6d4d

Please sign in to comment.