git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Clemens Buchacher <drizzd@aon.at>
To: Tay Ray Chuan <rctay89@gmail.com>
Cc: Git Mailing List <git@vger.kernel.org>,
	Junio C Hamano <gitster@pobox.com>,
	Johannes Schindelin <Johannes.Schindelin@gmx.de>,
	Mike Hommey <mh@glandium.org>
Subject: Re: [PATCH 14/17] http*: add http_get_info_packs
Date: Sun, 31 May 2009 17:02:56 +0200	[thread overview]
Message-ID: <20090531150256.GA27958@localhost> (raw)
In-Reply-To: <20090530015937.c402e5f2.rctay89@gmail.com>

On Sat, May 30, 2009 at 01:59:37AM +0800, Tay Ray Chuan wrote:
> --- a/http-push.c
> +++ b/http-push.c
> @@ -950,182 +950,16 @@ static int add_send_request(struct object *obj, struct remote_lock *lock)
[...]
>  static int fetch_indices(void)
>  {
[...]
> -		if (results.curl_result != CURLE_OK) {
> -			strbuf_release(&buffer);
> -			free(url);
> -			if (results.http_code == 404)
> -				return 0;
> -			else
> -				return error("%s", curl_errorstr);
> -		}
[...]
> +	if (http_get_info_packs(repo->url, &repo->packs) == HTTP_OK)
> +		return 0;
> +	else
> +		return -1;

fetch_indices() used to return 0 if the pack info was missing. Now it
returns an error. I also think we could get rid of repo->has_info_packs.
This could easily be handled within fetch_indices().

Clemens

  reply	other threads:[~2009-05-31 15:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-29 17:59 [PATCH 13/17] http-push.c::fetch_symref(): use the new http API Tay Ray Chuan
2009-05-29 17:59 ` [PATCH 14/17] http*: add http_get_info_packs Tay Ray Chuan
2009-05-31 15:02   ` Clemens Buchacher [this message]
2009-06-03 11:55     ` Tay Ray Chuan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090531150256.GA27958@localhost \
    --to=drizzd@aon.at \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=mh@glandium.org \
    --cc=rctay89@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).