On Tue, Sep 10, 2019 at 09:10:57AM -0600, Todd C. Miller wrote:
> 
> Let's just skip that check when fcodes is "-".
> 

I'am fine with it too.

ok semarie@

> 
> Index: usr.bin/locate/locate/updatedb.sh
> ===================================================================
> RCS file: /cvs/src/usr.bin/locate/locate/updatedb.sh,v
> retrieving revision 1.16
> diff -u -p -u -r1.16 updatedb.sh
> --- usr.bin/locate/locate/updatedb.sh 31 Aug 2019 16:03:28 -0000      1.16
> +++ usr.bin/locate/locate/updatedb.sh 10 Sep 2019 15:06:02 -0000
> @@ -70,10 +70,12 @@ while test $# != 0; do
>       shift
>  done
>  
> -FCODESDIR=$( dirname "${FCODES}" )
> -if [ ! -w "${FCODESDIR}" ]; then
> -     echo "$0: no permission to create $FCODES"
> -     exit 1
> +if [ "${FCODES}" != "-" ]; then
> +     FCODESDIR=$( dirname "${FCODES}" )
> +     if [ ! -w "${FCODESDIR}" ]; then
> +             echo "$0: no permission to create $FCODES"
> +             exit 1
> +     fi
>  fi
>  
>  case X"$SEARCHPATHS" in 

-- 
Sebastien Marie

Reply via email to