From 50ab6558bf688e15048e189bdaf9174b217e1748 Mon Sep 17 00:00:00 2001 From: Jonathan Nieder Date: Sat, 24 Apr 2010 07:15:37 -0500 Subject: request-pull: protect against OPTIONS_KEEPDASHDASH from environment MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Like most git commands, request-pull supports a -- delimiter to allow callers to pass arguments that would otherwise be treated as an option afterwards. The internal OPTIONS_KEEPDASHDASH variable is passed empty to git-sh-setup to indicate that request-pull itself does not care about the position of the -- delimiter. But if the user has that variable in her environment, request-pull will see the “--” and fail. Empty it explicitly to guard against this. While at it, make the corresponding fix to git-resurrect, too (all other scripts in git.git already protect themselves). Acked-by: Thomas Rast Acked-by: Miklos Vajna Signed-off-by: Jonathan Nieder Signed-off-by: Junio C Hamano --- git-request-pull.sh | 1 + 1 file changed, 1 insertion(+) (limited to 'git-request-pull.sh') diff --git a/git-request-pull.sh b/git-request-pull.sh index 630ceddf03..b0a03111cc 100755 --- a/git-request-pull.sh +++ b/git-request-pull.sh @@ -8,6 +8,7 @@ USAGE=' []' LONG_USAGE='Summarizes the changes between two commits to the standard output, and includes the given URL in the generated summary.' SUBDIRECTORY_OK='Yes' +OPTIONS_KEEPDASHDASH= OPTIONS_SPEC='git request-pull [options] start url [end] -- p show patch text as well -- cgit v1.2.3