From: Ramsay Jones <ramsay@ramsayjones.plus.com>
To: David Turner <dturner@twopensource.com>
Cc: Junio C Hamano <gitster@pobox.com>,
GIT Mailing-list <git@vger.kernel.org>
Subject: [PATCH] refs: reduce the visibility of do_for_each_ref()
Date: Tue, 23 Feb 2016 00:39:13 +0000 [thread overview]
Message-ID: <56CBAA31.7030809@ramsayjones.plus.com> (raw)
Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
---
Hi David,
Again, If you need to re-roll your 'dt/refs-backend-lmdb' branch ...
Thanks!
ATB,
Ramsay Jones
refs.c | 16 ++++++++--------
refs/refs-internal.h | 6 ------
2 files changed, 8 insertions(+), 14 deletions(-)
diff --git a/refs.c b/refs.c
index 337f110..bf70876 100644
--- a/refs.c
+++ b/refs.c
@@ -1236,6 +1236,14 @@ static int get_affected_refnames(struct ref_transaction *transaction,
return 0;
}
+static int do_for_each_ref(const char *submodule, const char *base,
+ each_ref_fn fn, int trim, int flags,
+ void *cb_data)
+{
+ return the_refs_backend->do_for_each_ref(submodule, base, fn, trim,
+ flags, cb_data);
+}
+
int for_each_ref(each_ref_fn fn, void *cb_data)
{
return do_for_each_ref(NULL, "", fn, 0, 0, cb_data);
@@ -1501,14 +1509,6 @@ int resolve_gitlink_ref(const char *path, const char *refname,
return the_refs_backend->resolve_gitlink_ref(path, refname, sha1);
}
-int do_for_each_ref(const char *submodule, const char *base,
- each_ref_fn fn, int trim, int flags,
- void *cb_data)
-{
- return the_refs_backend->do_for_each_ref(submodule, base, fn, trim,
- flags, cb_data);
-}
-
int for_each_reflog_ent_reverse(const char *refname, each_reflog_ent_fn fn,
void *cb_data)
{
diff --git a/refs/refs-internal.h b/refs/refs-internal.h
index ced6af4..4922e25 100644
--- a/refs/refs-internal.h
+++ b/refs/refs-internal.h
@@ -227,12 +227,6 @@ int do_for_each_per_worktree_ref(const char *submodule, const char *base,
each_ref_fn fn, int trim, int flags,
void *cb_data);
-/*
- * The common backend for the for_each_*ref* functions
- */
-int do_for_each_ref(const char *submodule, const char *base,
- each_ref_fn fn, int trim, int flags, void *cb_data);
-
/* refs backends */
typedef int ref_init_db_fn(int shared, struct strbuf *err);
typedef int ref_transaction_commit_fn(struct ref_transaction *transaction,
--
2.7.0
next reply other threads:[~2016-02-23 0:39 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-23 0:39 Ramsay Jones [this message]
2016-02-24 19:28 ` [PATCH] refs: reduce the visibility of do_for_each_ref() David Turner
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=56CBAA31.7030809@ramsayjones.plus.com \
--to=ramsay@ramsayjones.plus.com \
--cc=dturner@twopensource.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.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).