summaryrefslogtreecommitdiff
path: root/git-gui.sh
diff options
context:
space:
mode:
authorPratyush Yadav <me@yadavpratyush.com>2020-03-14 21:38:36 (GMT)
committerPratyush Yadav <me@yadavpratyush.com>2020-03-17 13:18:54 (GMT)
commit3891a84ccdad249c426c3e036d4fb086c388b4ce (patch)
tree470c477ade7cf95ad50df51075ef8224d587166d /git-gui.sh
parent8a8efbe4140fd732e1890cbba6eaa85c0fac85e2 (diff)
downloadgit-3891a84ccdad249c426c3e036d4fb086c388b4ce.zip
git-3891a84ccdad249c426c3e036d4fb086c388b4ce.tar.gz
git-3891a84ccdad249c426c3e036d4fb086c388b4ce.tar.bz2
git-gui: create a new namespace for chord script evaluation
Evaluating the script in the same namespace as the chord itself creates potential for variable name collision. And in that case the script would unknowingly use the chord's variables. For example, say the script has a variable called 'is_completed', which also exists in the chord's namespace. The script then calls 'eval' and sets 'is_completed' to 1 thinking it is setting its own variable, completely unaware of how the chord works behind the scenes. This leads to the chord never actually executing because it sees 'is_completed' as true and thinks it has already completed. Avoid the potential collision by creating a separate namespace for the script that is a child of the chord's namespace. Signed-off-by: Pratyush Yadav <me@yadavpratyush.com>
Diffstat (limited to 'git-gui.sh')
0 files changed, 0 insertions, 0 deletions