summaryrefslogtreecommitdiff
path: root/builtin/revert.c
diff options
context:
space:
mode:
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>2011-12-12 11:20:29 (GMT)
committerJunio C Hamano <gitster@pobox.com>2011-12-12 17:30:23 (GMT)
commite4776bd936aa162b7f00cb26260dc4a6ca444abb (patch)
tree2e7461b7694240e681eae877aaba44751008ba34 /builtin/revert.c
parent9859a023fef30ffebdd22ad9639c587ac720b8b6 (diff)
downloadgit-e4776bd936aa162b7f00cb26260dc4a6ca444abb.zip
git-e4776bd936aa162b7f00cb26260dc4a6ca444abb.tar.gz
git-e4776bd936aa162b7f00cb26260dc4a6ca444abb.tar.bz2
revert: convert resolve_ref() to read_ref_full()
This is the follow up of c689332 (Convert many resolve_ref() calls to read_ref*() and ref_exists() - 2011-11-13). See the said commit for rationale. 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 'builtin/revert.c')
-rw-r--r--builtin/revert.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/revert.c b/builtin/revert.c
index 1ea525c..0c52a83 100644
--- a/builtin/revert.c
+++ b/builtin/revert.c
@@ -901,7 +901,7 @@ static int rollback_single_pick(void)
if (!file_exists(git_path("CHERRY_PICK_HEAD")) &&
!file_exists(git_path("REVERT_HEAD")))
return error(_("no cherry-pick or revert in progress"));
- if (!resolve_ref("HEAD", head_sha1, 0, NULL))
+ if (read_ref_full("HEAD", head_sha1, 0, NULL))
return error(_("cannot resolve HEAD"));
if (is_null_sha1(head_sha1))
return error(_("cannot abort from a branch yet to be born"));