aboutsummaryrefslogtreecommitdiff
path: root/storage.c
diff options
context:
space:
mode:
author=2022-05-05 15:23:47 +0200
committer=2022-05-05 15:23:47 +0200
commit6afe3cc8ec6c009a43950bdbe138cbc2d7a88a4d (patch)
tree7c2854537fc1bdf5f5aa8e861cf676204d773967 /storage.c
parent2b1838ecf30fd91575a71b877965ed3363356138 (diff)
downloadsoikk-DB-6afe3cc8ec6c009a43950bdbe138cbc2d7a88a4d.tar.xz
soikk-DB-6afe3cc8ec6c009a43950bdbe138cbc2d7a88a4d.tar.zst
Quality of life changes
Diffstat (limited to 'storage.c')
-rw-r--r--storage.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/storage.c b/storage.c
index 5e7809b..2a5420b 100644
--- a/storage.c
+++ b/storage.c
@@ -6,6 +6,7 @@ row *newRow(const char path[MAXPATH]){
memcpy(nr->path, path, MAXPATH);
memcpy(nr->tags, "\0", MAXTAGS);
nr->numTags = 0;
+ nr->lenTags = 0;
return nr;
}
@@ -113,6 +114,7 @@ void insertTag(row *r, char *tag){
}
r->tags[tagnum] = '\0';
r->numTags = l;
+ r->lenTags = tagnum;
}
// Remove a tag from the tags array in the row r
@@ -153,4 +155,5 @@ void removeTag(row *r, char *tag){
}
r->tags[tagnum] = '\0';
r->numTags = l;
-} \ No newline at end of file
+ r->lenTags = tagnum;
+}