Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-11-05 22:50:24 +0300
committerJunio C Hamano <junkio@cox.net>2005-11-05 22:50:24 +0300
commit87ce294c9129879f717f8749cae1c659e18a3823 (patch)
tree7bda83efef0ee677e4e743954bc00bdcf6a63874 /http-fetch.c
parent6ddc0964034342519a87fe013781abf31c6db6ad (diff)
parent3d95bf074e8532fd0643b886422eddd0768a3f2c (diff)
GIT 0.99.9dv0.99.9d
This is primarily to include the 'git clone -l' (without -s) fix, first spotted and diagnosed by Linus and caused James Bottomley's repository to become unreadable. It also contains documentation updates happened on the "master" branch since 0.99.9c Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'http-fetch.c')
-rw-r--r--http-fetch.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/http-fetch.c b/http-fetch.c
index a1b03cd9c8..b12779dcb4 100644
--- a/http-fetch.c
+++ b/http-fetch.c
@@ -520,12 +520,17 @@ static void start_request(struct transfer_request *request)
static void finish_request(struct transfer_request *request)
{
+ struct stat st;
+
fchmod(request->local, 0444);
close(request->local);
if (request->http_code == 416) {
fprintf(stderr, "Warning: requested range invalid; we may already have all the data.\n");
} else if (request->curl_result != CURLE_OK) {
+ if (stat(request->tmpfile, &st) == 0)
+ if (st.st_size == 0)
+ unlink(request->tmpfile);
return;
}