[X2Go-Commits] [x2goclient] 68/257: deduplicate.sh: prevent word splitting when parsing otool's output.

git-admin at x2go.org git-admin at x2go.org
Mon Nov 28 16:05:11 CET 2016


This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch bugfix/osx
in repository x2goclient.

commit 7f9518eb46c05e12e41e4d02a06a345302478fa2
Author: Mihai Moldovan <ionic at ionic.de>
Date:   Thu Aug 27 04:59:27 2015 +0200

    deduplicate.sh: prevent word splitting when parsing otool's output.
    
    We want the raw bits.
---
 debian/changelog |    2 ++
 deduplicate.sh   |    6 ++++++
 2 files changed, 8 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index e32b4bb..73ad55c 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -127,6 +127,8 @@ x2goclient (4.0.5.3-0x2go1) UNRELEASED; urgency=medium
     - deduplicate.sh: record crafted "library path" values in duplicates
       replacement to_files array.
     - deduplicate.sh: debug parse_otool_output fiercely for the time being.
+    - deduplicate.sh: prevent word splitting when parsing otool's output. We
+      want the raw bits.
 
   [ Bernard Cafarelli ]
   * New upstream version (4.0.5.3):
diff --git a/deduplicate.sh b/deduplicate.sh
index 5e1000f..93a5c8f 100755
--- a/deduplicate.sh
+++ b/deduplicate.sh
@@ -24,6 +24,11 @@ set -x
 
 	typeset tmp_regex='^[[:space:]]+(.*)[[:space:]]\(compatibility version .*, current version .*\)'
 
+
+	# In this special case, we do not want read to perform any word splitting.
+	typeset oldifs="${IFS}"
+	IFS=''
+
 	typeset line=""
 	while read -r line; do
 		if [[ "${line}" =~ ${tmp_regex} ]]; then
@@ -31,6 +36,7 @@ set -x
 		fi
 	done <<< "${raw_output}"
 
+	IFS="${oldifs}"
 set +x
 	return 0
 }

--
Alioth's /srv/git/code.x2go.org/x2goclient.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/x2goclient.git


More information about the x2go-commits mailing list