Skip to content

Commit 0bf0de6

Browse files
ttaylorrgitster
authored andcommitted
packfile: make close_pack_revindex() static
Since its definition in 2f4ba2a (packfile: prepare for the existence of '*.rev' files, 2021-01-25), the only caller of `close_pack_revindex()` was within packfile.c. Thus there is no need for this to be exposed via packfile.h, and instead can remain static within packfile.c's compilation unit. While we're here, move the function's opening brace onto its own line. Noticed-by: Ramsay Jones <[email protected]> Signed-off-by: Taylor Blau <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 6885cd7 commit 0bf0de6

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packfile.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,8 @@ void close_pack_index(struct packed_git *p)
324324
}
325325
}
326326

327-
void close_pack_revindex(struct packed_git *p) {
327+
static void close_pack_revindex(struct packed_git *p)
328+
{
328329
if (!p->revindex_map)
329330
return;
330331

packfile.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,6 @@ uint32_t get_pack_fanout(struct packed_git *p, uint32_t value);
9090

9191
unsigned char *use_pack(struct packed_git *, struct pack_window **, off_t, unsigned long *);
9292
void close_pack_windows(struct packed_git *);
93-
void close_pack_revindex(struct packed_git *);
9493
void close_pack(struct packed_git *);
9594
void close_object_store(struct raw_object_store *o);
9695
void unuse_pack(struct pack_window **);

0 commit comments

Comments
 (0)