1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-06-10 05:16:15 +02:00

Fix double-free() in http-push.c:remote_exists()

Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Grégoire Barbier 2007-12-30 18:15:51 +01:00 committed by Junio C Hamano
parent 441ed4131b
commit d6ed263fc7

View File

@ -1979,7 +1979,6 @@ static int remote_exists(const char *path)
if (start_active_slot(slot)) {
run_active_slot(slot);
free(url);
if (results.http_code == 404)
ret = 0;
else if (results.curl_result == CURLE_OK)
@ -1987,7 +1986,6 @@ static int remote_exists(const char *path)
else
fprintf(stderr, "HEAD HTTP error %ld\n", results.http_code);
} else {
free(url);
fprintf(stderr, "Unable to start HEAD request\n");
}