diff options
author | Emmanuel Dreyfus <manu@netbsd.org> | 2014-11-04 15:56:36 +0100 |
---|---|---|
committer | Vijay Bellur <vbellur@redhat.com> | 2014-11-13 22:20:12 -0800 |
commit | a537342633707544c645cba0c3d46f2180c3b570 (patch) | |
tree | 7acb7d79b5c9e385af904571dd457afebeef157b /xlators/mount | |
parent | 77a6917a650a88c12b6c27d37994f8bfef461345 (diff) |
Portability fix: mount.glusterfs
Remove bash-specific syntax from mount.glusterfs
BUG: 1129939
Change-Id: Iec3a52686f7cee1825ac5a06c11fb8ac4d3e5d65
Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org>
Reviewed-on: http://review.gluster.org/9044
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'xlators/mount')
-rwxr-xr-x | xlators/mount/fuse/utils/mount_glusterfs.in | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/xlators/mount/fuse/utils/mount_glusterfs.in b/xlators/mount/fuse/utils/mount_glusterfs.in index e0a06ea6925..dc326b4528f 100755 --- a/xlators/mount/fuse/utils/mount_glusterfs.in +++ b/xlators/mount/fuse/utils/mount_glusterfs.in @@ -449,7 +449,7 @@ without_options() parse_options() { local optarg=${1} - for pair in $(echo ${optarg//,/ }); do + for pair in $(echo $optarg | sed 's/,/ /g'); do key=$(echo "$pair" | cut -f1 -d'='); value=$(echo "$pair" | cut -f2- -d'='); if [ "$key" = "$value" ]; then @@ -463,7 +463,8 @@ parse_options() main () { ## `mount` on OSX specifies options as first argument - if [[ $1 =~ "-o" ]]; then + echo $1|grep -q -- "-o" + if [ $? -eq 0 ]; then volfile_loc=$3 mount_point=$4 else |