AmendHub

Download (as of this amendment):

jcs

/

amend

/

amendments

/

173

repo: Zero file_ids when no files in the repo


jcs made amendment 173 24 days ago
--- repo.c Mon Sep 28 14:17:43 2026 +++ repo.c Mon Sep 28 14:23:49 2026 @@ -200,7 +200,7 @@ repo_load_amendments(struct repo *repo, bool fill_in) break; } if (repo->unloaded_amendments && - i < repo->namendments - settings.max_amendments - 1) + i < repo->namendments - settings.max_amendments) continue; if (fill_in && repo->amendments[i] != NULL) continue; @@ -347,6 +347,8 @@ repo_parse_amendment(unsigned long id, unsigned char * amendment->file_ids[i] = (data[0] << 8) | data[1]; data += 2; } + } else { + amendment->file_ids = NULL; } /* additions, short */