Skip to content

Commit

Permalink
fix(database): set data that not changed
Browse files Browse the repository at this point in the history
  • Loading branch information
aloima committed Sep 13, 2024
1 parent 3a13763 commit 7fd9ed6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/database/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ void save_data() {

diff += line_len - line_len_in_file;
} else {
fseek(file, pair->pos, SEEK_SET);
fseek(file, pair->pos + diff, SEEK_SET);
fwrite(line, sizeof(char), line_len, file);
}
} else {
Expand Down

0 comments on commit 7fd9ed6

Please sign in to comment.