From b044e48c7005ecb4233e7d6991876ebe3b673edc Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Sun, 22 Nov 2015 11:24:01 -0800 Subject: Quote the source directory in Git commands. It may contain spaces (it does on my Windows 7 VM), so it must be quoted. (There are probably other places where it needs to be quoted in this script.) Change-Id: If363691b0f94bbe75755072fd5245266566c3360 Reviewed-on: https://code.wireshark.org/review/12043 Reviewed-by: Guy Harris --- make-version.pl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'make-version.pl') diff --git a/make-version.pl b/make-version.pl index 0eee0beaba..62312e6c78 100755 --- a/make-version.pl +++ b/make-version.pl @@ -163,13 +163,13 @@ sub read_repo_info { use warnings "all"; no warnings "all"; - chomp($line = qx{git --git-dir=$srcdir/.git log -1 --pretty=format:%at}); + chomp($line = qx{git --git-dir="$srcdir"/.git log -1 --pretty=format:%at}); if ($? == 0 && length($line) > 1) { $last_change = $line; } # Commits since last annotated tag. - chomp($line = qx{git --git-dir=$srcdir/.git describe --long --always --match "v*"}); + chomp($line = qx{git --git-dir="$srcdir"/.git describe --long --always --match "v*"}); if ($? == 0 && length($line) > 1) { my @parts = split(/-/, $line); $git_description = $line; @@ -179,7 +179,7 @@ sub read_repo_info { # This will break in some cases. Hopefully not during # official package builds. - chomp($line = qx{git --git-dir=$srcdir/.git rev-parse --abbrev-ref --symbolic-full-name \@\{upstream\}}); + chomp($line = qx{git --git-dir="$srcdir"/.git rev-parse --abbrev-ref --symbolic-full-name \@\{upstream\}}); if ($? == 0 && length($line) > 1) { $repo_branch = basename($line); } -- cgit v1.2.1