From: Ronnie Sahlberg <sahlb...@google.com> This function can be shared across all refs backends so move it to the common code.
Signed-off-by: Ronnie Sahlberg <sahlb...@google.com> Signed-off-by: David Turner <dtur...@twitter.com> --- refs-be-files.c | 7 ------- refs.c | 7 +++++++ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/refs-be-files.c b/refs-be-files.c index f67ff41..6328e75 100644 --- a/refs-be-files.c +++ b/refs-be-files.c @@ -1786,13 +1786,6 @@ const char *resolve_ref_unsafe(const char *refname, int resolve_flags, return ret; } -char *resolve_refdup(const char *refname, int resolve_flags, - unsigned char *sha1, int *flags) -{ - return xstrdup_or_null(resolve_ref_unsafe(refname, resolve_flags, - sha1, flags)); -} - /* The argument to filter_refs */ struct ref_filter { const char *pattern; diff --git a/refs.c b/refs.c index 242f66d..039e5c0 100644 --- a/refs.c +++ b/refs.c @@ -651,3 +651,10 @@ int ref_exists(const char *refname) unsigned char sha1[20]; return !!resolve_ref_unsafe(refname, RESOLVE_REF_READING, sha1, NULL); } + +char *resolve_refdup(const char *refname, int resolve_flags, + unsigned char *sha1, int *flags) +{ + return xstrdup_or_null(resolve_ref_unsafe(refname, resolve_flags, + sha1, flags)); +} -- 2.0.4.315.gad8727a-twtrsrc -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html