Skip to content

Commit 910710b

Browse files
bk2204gitster
authored andcommitted
server-info: remove unused members from struct pack_info
The head member of struct pack_info is completely unused and the nr_heads member is used only in one place, which is an assignment. This member was last usefully used in 3e15c67 (server-info: throw away T computation as well, 2005-12-04). Since this structure member is not useful, remove it. Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent 69d1242 commit 910710b

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

server-info.c

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,6 @@ static struct pack_info {
9292
int old_num;
9393
int new_num;
9494
int nr_alloc;
95-
int nr_heads;
96-
unsigned char (*head)[20];
9795
} **info;
9896
static int num_pack;
9997
static const char *objdir;
@@ -225,12 +223,9 @@ static void init_pack_info(const char *infofile, int force)
225223
else
226224
stale = 1;
227225

228-
for (i = 0; i < num_pack; i++) {
229-
if (stale) {
226+
for (i = 0; i < num_pack; i++)
227+
if (stale)
230228
info[i]->old_num = -1;
231-
info[i]->nr_heads = 0;
232-
}
233-
}
234229

235230
/* renumber them */
236231
QSORT(info, num_pack, compare_info);

0 commit comments

Comments
 (0)