summaryrefslogtreecommitdiff
path: root/refs.h
diff options
context:
space:
mode:
authorRonnie Sahlberg <sahlberg@google.com>2014-09-11 17:34:36 (GMT)
committerJunio C Hamano <gitster@pobox.com>2014-10-15 17:47:25 (GMT)
commit18f29fc61ed88145a0664657c3cea9e9732ea5e8 (patch)
tree6f208e327b47bf35a3d6e52018c045aeab3ec9d7 /refs.h
parent62a2d52514aed2b684409cb48e40e0cd14335d1b (diff)
downloadgit-18f29fc61ed88145a0664657c3cea9e9732ea5e8.zip
git-18f29fc61ed88145a0664657c3cea9e9732ea5e8.tar.gz
git-18f29fc61ed88145a0664657c3cea9e9732ea5e8.tar.bz2
branch -d: simplify by using RESOLVE_REF_READING
When "git branch -d" reads the branch it is about to delete, it used to avoid passing the RESOLVE_REF_READING ('treat missing ref as error') flag because a symref pointing to a nonexistent ref would show up as missing instead of as something that could be deleted. To check if a ref is actually missing, we then check - is it a symref? - if not, did it resolve to null_sha1? Now we pass RESOLVE_REF_NO_RECURSE and the correct information is returned for a symref even when it points to a missing ref. Simplify by relying on RESOLVE_REF_READING. No functional change intended. Signed-off-by: Ronnie Sahlberg <sahlberg@google.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'refs.h')
0 files changed, 0 insertions, 0 deletions