Explicitly add the default "git pull" behaviour to .git/config on clone
[gitweb.git] / git-merge.sh
index 272f004622572ad2aed62268d9a75cac5a8fa751..a948878b911f56a3d6ace784d5a93952ce25c64b 100755 (executable)
@@ -188,8 +188,9 @@ else
        # in this loop.
        merge_name=$(for remote
                do
-                       rh=$(git-rev-parse --verify "$remote"^0 2>/dev/null) &&
-                       bh=$(git show-ref -s --verify "refs/heads/$remote") &&
+                       rh=$(git-rev-parse --verify "$remote"^0 2>/dev/null) ||
+                       continue ;# not something we can merge
+                       bh=$(git show-ref -s --verify "refs/heads/$remote" 2>/dev/null)
                        if test "$rh" = "$bh"
                        then
                                echo "$rh               branch '$remote' of ."