From: Jonas Fonseca Date: Tue, 12 Sep 2006 00:23:16 +0000 (+0200) Subject: Oops, always update the tree view ref X-Git-Tag: tig-0.5~21 X-Git-Url: https://git.distorted.org.uk/~mdw/tig/commitdiff_plain/ebbaf4fe5b6a8a0ef52120587495594e6dcf4752?hp=73c76ef5c12ef914484e1ee71e55126d74020c8d Oops, always update the tree view ref --- diff --git a/tig.c b/tig.c index 6236bf3..0a86490 100644 --- a/tig.c +++ b/tig.c @@ -2617,9 +2617,11 @@ tree_select(struct view *view, struct line *line) * be in sync. */ string_copy(VIEW(REQ_VIEW_BLOB)->ref, ref_blob); - } else if (line->type == LINE_TREE_DIR) { - string_ncopy(view->ref, text, 40); + } else if (line->type != LINE_TREE_DIR) { + return; } + + string_ncopy(view->ref, text, 40); } static struct view_ops tree_ops = {