Code

Extend sample update hook, disable modifying of existing tags
[git.git] / builtin-merge.c
index c339380cf3a94c5c157e7b3fae082ea2321320fc..0b58e5eda1f38c1560cc9dcf69be37fa5fc9886f 100644 (file)
@@ -360,9 +360,8 @@ static void merge_name(const char *remote, struct strbuf *msg)
        const char *ptr;
        int len, early;
 
-       len = strlen(remote);
-       if (interpret_nth_last_branch(remote, &bname) == len)
-               remote = bname.buf;
+       strbuf_branchname(&bname, remote);
+       remote = bname.buf;
 
        memset(branch_head, 0, sizeof(branch_head));
        remote_head = peel_to_type(remote, 0, NULL, OBJ_COMMIT);
@@ -636,7 +635,7 @@ static int checkout_fast_forward(unsigned char *head, unsigned char *remote)
        memset(&opts, 0, sizeof(opts));
        memset(&t, 0, sizeof(t));
        memset(&dir, 0, sizeof(dir));
-       dir.show_ignored = 1;
+       dir.flags |= DIR_SHOW_IGNORED;
        dir.exclude_per_dir = ".gitignore";
        opts.dir = &dir;