diff options
author | Junio C Hamano <gitster@pobox.com> | 2020-05-01 23:39:53 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-05-01 23:39:53 +0300 |
commit | cf054f817a30cf4a6531548f52cd7d5cbed6f4fc (patch) | |
tree | 1a22fdf3be94217a1427f8728dc1bf3a0e25692e /commit-graph.h | |
parent | 6a1c17d05b0e67fa5f9661f492f407b984496b27 (diff) | |
parent | c8828530b7797f5ab584c84dc2b86d3c14b39c8d (diff) |
Merge branch 'tb/commit-graph-fd-exhaustion-fix'
The commit-graph code exhausted file descriptors easily when it
does not have to.
* tb/commit-graph-fd-exhaustion-fix:
commit-graph: close descriptors after mmap
commit-graph.c: gracefully handle file descriptor exhaustion
t/test-lib.sh: make ULIMIT_FILE_DESCRIPTORS available to tests
commit-graph.c: don't use discarded graph_name in error
Diffstat (limited to 'commit-graph.h')
-rw-r--r-- | commit-graph.h | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/commit-graph.h b/commit-graph.h index 98ef121924..1254eae948 100644 --- a/commit-graph.h +++ b/commit-graph.h @@ -40,8 +40,6 @@ struct tree *get_commit_tree_in_graph(struct repository *r, const struct commit *c); struct commit_graph { - int graph_fd; - const unsigned char *data; size_t data_len; @@ -66,8 +64,7 @@ struct commit_graph *load_commit_graph_one_fd_st(int fd, struct stat *st, struct object_directory *odb); struct commit_graph *read_commit_graph_one(struct repository *r, struct object_directory *odb); -struct commit_graph *parse_commit_graph(void *graph_map, int fd, - size_t graph_size); +struct commit_graph *parse_commit_graph(void *graph_map, size_t graph_size); /* * Return 1 if and only if the repository has a commit-graph |