Skip to content

Commit fde566f

Browse files
committed
Merge branch 'js/rebase-am-options-fix'
Recently, built-in "rebase" tightened the error checking for a few options that are passed to underlying "am", but we forgot to make the matching change to the scripted version, which has been corrected. * js/rebase-am-options-fix: legacy-rebase: backport -C<n> and --whitespace=<option> checks
2 parents c17f086 + 7e097e2 commit fde566f

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

git-legacy-rebase.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -337,6 +337,11 @@ do
337337
fix|strip)
338338
force_rebase=t
339339
;;
340+
warn|nowarn|error|error-all)
341+
;; # okay, known whitespace option
342+
*)
343+
die "fatal: Invalid whitespace option: '${1#*=}'"
344+
;;
340345
esac
341346
;;
342347
--ignore-whitespace)
@@ -352,6 +357,9 @@ do
352357
git_am_opt="$git_am_opt $1"
353358
force_rebase=t
354359
;;
360+
-C*[!0-9]*)
361+
die "fatal: switch \`C' expects a numerical value"
362+
;;
355363
-C*)
356364
git_am_opt="$git_am_opt $1"
357365
;;

0 commit comments

Comments
 (0)