author | Junio C Hamano <junkio@cox.net> | |
Tue, 11 Oct 2005 06:22:01 +0000 (23:22 -0700) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Tue, 11 Oct 2005 06:22:01 +0000 (23:22 -0700) | ||
commit | b721e01f6efd84b04c6946553cd566f2707c964d | |
tree | 4f34bf130613e28cb2391efdcf270d885412ec0a | tree | snapshot |
parent | 031260064840e6e8c6bc36d7856a091ba80330c2 | commit | diff |
Use the same move_temp_to_file in git-http-fetch.
The http commit walker cannot use the same temporary file
creation code because it needs to use predictable temporary
filename for partial fetch continuation purposes, but the code
to move the temporary file to the final location should be
usable from the ordinary object creation codepath.
Export move_temp_to_file from sha1_file.c and use it, while
losing the custom relink_or_rename function from http-fetch.c.
Also the temporary object file creation part needs to make sure
the leading path exists, in preparation of the really lazy
fan-out directory creation.
Signed-off-by: Junio C Hamano <junkio@cox.net>
The http commit walker cannot use the same temporary file
creation code because it needs to use predictable temporary
filename for partial fetch continuation purposes, but the code
to move the temporary file to the final location should be
usable from the ordinary object creation codepath.
Export move_temp_to_file from sha1_file.c and use it, while
losing the custom relink_or_rename function from http-fetch.c.
Also the temporary object file creation part needs to make sure
the leading path exists, in preparation of the really lazy
fan-out directory creation.
Signed-off-by: Junio C Hamano <junkio@cox.net>
cache.h | diff | blob | history | |
http-fetch.c | diff | blob | history | |
sha1_file.c | diff | blob | history |