From: Phil Hord <hordp@cisco.com>
To: "git@vger.kernel.org" <git@vger.kernel.org>,
Phil Hord <phil.hord@gmail.com>
Cc: Junio C Hamano <gitster@pobox.com>,
Erik Faye-Lund <kusmabite@gmail.com>,
Nguyen Thai Ngoc Duy <pclouds@gmail.com>
Subject: [PATCHv3 4/5] Teach transport about the gitfile mechanism
Date: Wed, 05 Oct 2011 09:35:10 -0400 [thread overview]
Message-ID: <4E8C5D0E.6080207@cisco.com> (raw)
The transport_get() function assumes that a regular file is a
bundle rather than a local git directory. Check if the file is
actually a gitfile. If so, do not try to process it as a
bundle, but treat it as a local repository instead.
Signed-off-by: Phil Hord <hordp@cisco.com>
diff --git a/transport.c b/transport.c
index cd49a25..2ff2d68 100644
--- a/transport.c
+++ b/transport.c
@@ -915,7 +915,7 @@ struct transport *transport_get(struct remote *remote, const char *url)
ret->fetch = fetch_objs_via_rsync;
ret->push = rsync_transport_push;
ret->smart_options = NULL;
- } else if (is_local(url) && is_file(url)) {
+ } else if (is_local(url) && is_file(url) && !is_gitfile(url)) {
struct bundle_transport_data *data = xcalloc(1, sizeof(*data));
ret->data = data;
ret->get_refs_list = get_refs_from_bundle;
--
1.7.7.505.ga09f6
reply other threads:[~2011-10-05 13:36 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4E8C5D0E.6080207@cisco.com \
--to=hordp@cisco.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=kusmabite@gmail.com \
--cc=pclouds@gmail.com \
--cc=phil.hord@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.
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 NNTP newsgroup(s).