'mount -p' can return multiple mount points. Use the first one. NSPRPUB_PRE_4_2_CLIENT_BRANCH
authorseawood%netscape.com
Wed, 02 Apr 2003 20:48:10 +0000
branchNSPRPUB_PRE_4_2_CLIENT_BRANCH
changeset 2781 23d81e67c245969cfc6da40c47247e88cc35583a
parent 2780 ab3a713a09dd39449bc88f7f5e84f8707e58494d
child 2782 188e8b2bbc119635878958d5a5c726fd7e6ab98a
push idunknown
push userunknown
push dateunknown
bugs158920
'mount -p' can return multiple mount points. Use the first one. Bug #158920 r=sspitzer
build/cygwin-wrapper
--- a/build/cygwin-wrapper
+++ b/build/cygwin-wrapper
@@ -2,17 +2,17 @@
 #
 # Stupid wrapper to avoid win32 dospath/cygdrive issues
 #
 prog=$1
 shift
 if test -z "$prog"; then
     exit 0
 fi
-mountpoint=`mount -p | grep ^/ | awk '{ print $1 }'`
+mountpoint=`mount -p | awk '{ if (/^\//) print $1 }' | head -1`
 if test -z "$mountpoint"; then
    print "Cannot determine cygwin mount points. Exiting"
    exit 1
 fi
 mountpoint=`echo $mountpoint | sed 's|/$||'`
 if test "$prog" = "-up"; then
    prog=$1
    shift