@matheusbsbs / matheus-bagliano / commits / 306fc12462
Fork 0

git-gui: Tighten internal pattern match for lib/ directory

Our GITGUI_LIBDIR macro was testing only for @@ at the start of the path, assuming nobody would ever find that to be a reasonable prefix for a directory to install our library into. That is most likely a valid assumption, but its even more unlikely they would have the start be @@GITGUI_ and the end be @@. Note that we cannot use the full string here because that would get expanded by the sed replacement in our Makefile. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>

Shawn O. Pearce committed May 22, 2007 at 03:22 UTC 306fc124621657234b21dce542496440d53147a6
1 file changed +1 -1
git-gui.sh
+1 -1
@@ -25,7 +25,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA}
25 ## configure our library
26
27 set oguilib {@@GITGUI_LIBDIR@@}
28 -if {[string match @@* $oguilib]} {
28 +if {[string match @@GITGUI_*@@ $oguilib]} {
29 set oguilib [file join [file dirname [file normalize $argv0]] lib]
30 }
31 set idx [file join $oguilib tclIndex]