We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f7991d1 commit 01af249Copy full SHA for 01af249
builtin-gc.c
@@ -134,19 +134,9 @@ static int too_many_packs(void)
134
135
prepare_packed_git();
136
for (cnt = 0, p = packed_git; p; p = p->next) {
137
- char path[PATH_MAX];
138
- size_t len;
139
- int keep;
140
-
141
if (!p->pack_local)
142
continue;
143
- len = strlen(p->pack_name);
144
- if (PATH_MAX <= len + 1)
145
- continue; /* oops, give up */
146
- memcpy(path, p->pack_name, len-5);
147
- memcpy(path + len - 5, ".keep", 6);
148
- keep = access(p->pack_name, F_OK) && (errno == ENOENT);
149
- if (keep)
+ if (p->pack_keep)
150
151
/*
152
* Perhaps check the size of the pack and count only
0 commit comments