diff options
author | Nguyễn Thái Ngọc Duy <pclouds@gmail.com> | 2019-04-06 18:34:26 +0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2019-04-08 17:26:32 +0900 |
commit | 8f56e9d4baa836a4a3cd56767457d6122de7ce1d (patch) | |
tree | 03f7be684fc4529397db0e28e429255f6e1cc251 /cache.h | |
parent | refs.c: add refs_shorten_unambiguous_ref() (diff) | |
download | tgif-8f56e9d4baa836a4a3cd56767457d6122de7ce1d.tar.xz |
refs.c: remove the_repo from substitute_branch_name()
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'cache.h')
-rw-r--r-- | cache.h | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -1468,8 +1468,12 @@ extern int parse_oid_hex(const char *hex, struct object_id *oid, const char **en #define INTERPRET_BRANCH_LOCAL (1<<0) #define INTERPRET_BRANCH_REMOTE (1<<1) #define INTERPRET_BRANCH_HEAD (1<<2) -extern int interpret_branch_name(const char *str, int len, struct strbuf *, - unsigned allowed); +int repo_interpret_branch_name(struct repository *r, + const char *str, int len, + struct strbuf *buf, + unsigned allowed); +#define interpret_branch_name(str, len, buf, allowed) \ + repo_interpret_branch_name(the_repository, str, len, buf, allowed) extern int get_oid_mb(const char *str, struct object_id *oid); extern int validate_headref(const char *ref); |