提交 cff93397 编写于 作者: S Shawn O. Pearce

git-gui: Disable Tk send in all git-gui sessions

The Tk designers blessed us with the "send" command, which on X11
will allow anyone who can connect to your X server to evaluate any
Tcl code they desire within any running Tk process.  This is just
plain nuts.  If git-gui wants someone running Tcl code within it
then would ask someone to supply that Tcl code to it; waiting for
someone to drop any random Tcl code into us is not fantastic idea.

By renaming send to the empty name the procedure will be removed
from the global namespace and Tk will stop responding to random Tcl
evaluation requests sent through the X server.  Since there is no
facility to filter these requests it is unlikely that we will ever
consider enabling this command.
Signed-off-by: NShawn O. Pearce <spearce@spearce.org>
上级 0b883ab3
......@@ -42,6 +42,8 @@ if {[catch {package require Tcl 8.4} err]
exit 1
}
rename send {} ; # What an evil concept...
######################################################################
##
## enable verbose loading?
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册