]> git.ipfire.org Git - thirdparty/git.git/commit
git-gui: pass redirections as separate argument to git_read
authorJohannes Sixt <j6t@kdbg.org>
Sun, 4 May 2025 13:39:03 +0000 (15:39 +0200)
committerTaylor Blau <me@ttaylorr.com>
Fri, 23 May 2025 21:04:24 +0000 (17:04 -0400)
commit60b0ba0a04c413b716dc33f83285ede26e820668
tree163c7c42dc0e035dd72a9f9d41559982df3138e8
parent1e0a93c3d35c84547b21ba704a9c4383d4360140
git-gui: pass redirections as separate argument to git_read

We are going to treat command arguments and redirections differently to
avoid passing arguments that look like redirections to the command
accidentally. To do so, it will be necessary to know which arguments
are intentional redirections. Rewrite direct call sites of git_read
to pass intentional redirections as a second (optional) argument.

git_read defers to safe_open_command, but we cannot make it safe, yet,
because one of the callers of git_read is proc git, which does not yet
know which of its arguments are redirections. This is the topic of the
next commit.

Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Taylor Blau <me@ttaylorr.com>
git-gui.sh
lib/checkout_op.tcl
lib/choose_repository.tcl
lib/console.tcl
lib/merge.tcl