From: Ulrich Drepper Date: Mon, 21 Apr 1997 13:34:31 +0000 (+0000) Subject: Handle files in the same directory correctly. X-Git-Tag: cvs/libc-2_0_4~100 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e2d554858b9a291fb9b9515ed5f8dbc850d7ea11;p=thirdparty%2Fglibc.git Handle files in the same directory correctly. --- diff --git a/rellns-sh b/rellns-sh index e66010d513d..890f4eea3a4 100755 --- a/rellns-sh +++ b/rellns-sh @@ -27,7 +27,11 @@ if test -d $1; then to=`cd $1 && /bin/pwd` else temp=`echo $1 | sed 's%/*[^/]*$%%'` - to=`cd $temp && /bin/pwd` + if test -z "$temp"; then + to=`/bin/pwd` + else + to=`cd $temp && /bin/pwd` + fi to="$to/`echo $1 | sed 's%.*/\([^/][^/]*\)$%\1%'`" fi to=`echo $to | sed 's%^/%%'`