Merge branch 'cc/hooks-doc'
[gitweb.git] / git-rebase.sh
index 9b13b833cb5762542848ee3e85e23d3ca0f76fa6..fbb0f288b3243bad5c358c6e8ecfb351aeaa52e8 100755 (executable)
@@ -353,7 +353,7 @@ orig_head=$branch
 mb=$(git merge-base "$onto" "$branch")
 if test "$upstream" = "$onto" && test "$mb" = "$onto" &&
        # linear history?
-       ! git rev-list --parents "$onto".."$branch" | grep " .* " > /dev/null
+       ! (git rev-list --parents "$onto".."$branch" | grep " .* ") > /dev/null
 then
        # Lazily switch to the target branch if needed...
        test -z "$switch_to" || git checkout "$switch_to"