diff options
author | Junio C Hamano <gitster@pobox.com> | 2019-06-13 22:19:43 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2019-06-13 22:19:43 +0200 |
commit | 2a983b227dd6df4d8db6e53e2f5be8afad061b60 (patch) | |
tree | 7dd65fe43580ec0eea3899479f28b849191b6e57 /packfile.c | |
parent | Merge branch 'ew/update-server-info' (diff) | |
parent | Use xmmap_gently instead of xmmap in use_pack (diff) | |
download | git-2a983b227dd6df4d8db6e53e2f5be8afad061b60.tar.xz git-2a983b227dd6df4d8db6e53e2f5be8afad061b60.zip |
Merge branch 'mh/import-transport-fd-fix'
The ownership rule for the file descriptor to fast-import remote
backend was mixed up, leading to unrelated file descriptor getting
closed, which has been fixed.
* mh/import-transport-fd-fix:
Use xmmap_gently instead of xmmap in use_pack
dup() the input fd for fast-import used for remote helpers
Diffstat (limited to 'packfile.c')
-rw-r--r-- | packfile.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/packfile.c b/packfile.c index 49c8544ff4..d786ec7312 100644 --- a/packfile.c +++ b/packfile.c @@ -640,7 +640,7 @@ unsigned char *use_pack(struct packed_git *p, while (packed_git_limit < pack_mapped && unuse_one_window(p)) ; /* nothing */ - win->base = xmmap(NULL, win->len, + win->base = xmmap_gently(NULL, win->len, PROT_READ, MAP_PRIVATE, p->pack_fd, win->offset); if (win->base == MAP_FAILED) |