Skip to content

Commit 50f1abc

Browse files
dschogitster
authored andcommitted
packfile.c: fix a typo in each_file_in_pack_dir_fn()'s declaration
One parameter is called `file_pach`. On the face of it, this looks as if it was supposed to talk about a `path` instead of a `pach`. However, looking at the way this callback is called, it gets fed the `d_name` from a directory entry, which provides just the file name, not the full path. Therefore, let's fix this by calling the parameter `file_name` instead. Signed-off-by: Johannes Schindelin <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 61a22dd commit 50f1abc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packfile.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ const char *pack_basename(struct packed_git *p);
5454
struct packed_git *parse_pack_index(unsigned char *sha1, const char *idx_path);
5555

5656
typedef void each_file_in_pack_dir_fn(const char *full_path, size_t full_path_len,
57-
const char *file_pach, void *data);
57+
const char *file_name, void *data);
5858
void for_each_file_in_pack_dir(const char *objdir,
5959
each_file_in_pack_dir_fn fn,
6060
void *data);

0 commit comments

Comments
 (0)