GNU bug report logs - #29167
tests/ls/readdir-mountpoint-inode.sh is unstable and should require root privileges

Previous Next

Package: coreutils;

Reported by: Thomas Deutschmann <whissi <at> gentoo.org>

Date: Mon, 6 Nov 2017 10:43:02 UTC

Severity: normal

Done: Pádraig Brady <P <at> draigBrady.com>

Bug is archived. No further changes may be made.

Full log


Message #13 received at 29167-done <at> debbugs.gnu.org (full text, mbox):

From: Pádraig Brady <P <at> draigBrady.com>
To: Thomas Deutschmann <whissi <at> gentoo.org>, 29167-done <at> debbugs.gnu.org
Subject: Re: bug#29167: Acknowledgement (tests/ls/readdir-mountpoint-inode.sh
 is unstable and should require root privileges)
Date: Mon, 6 Nov 2017 21:37:25 -0800
On 06/11/17 04:06, Thomas Deutschmann wrote:
> Hi,
> 
> here's a better fix (from Sebastian Kühn via
> https://bugs.gentoo.org/353164):
> 
> diff --git a/tests/ls/readdir-mountpoint-inode.sh
> b/tests/ls/readdir-mountpoint-inode.sh
> index b4ca9e46e..5270df079 100755
> --- a/tests/ls/readdir-mountpoint-inode.sh
> +++ b/tests/ls/readdir-mountpoint-inode.sh
> @@ -55,7 +55,10 @@ inode_via_readdir()
>    esac
>    opts=$(ls_ignore_options "$base")
>    parent_dir=$(dirname "$mount_point")
> -  eval "ls -i $opts '$parent_dir'" | sed 's/ .*//'
> +  ls_out=$(eval "ls -i $opts '$parent_dir'")
> +  test $? -eq 0 || \
> +    skip_ "'$parent_dir' is not readable for current user"
> +  echo $ls_out | sed 's/ .*//'
>  }
> 
>  while read dir; do

Pushed at:
https://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=v8.28-29-gaebefc2
Marking this as done.

thanks,
Pádraig




This bug report was last modified 7 years and 256 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.