From 92d1ab60b2e898e7059686f3b65ccaf31b963129 Mon Sep 17 00:00:00 2001 From: freesource Date: Tue, 23 Oct 2001 16:47:35 +0000 Subject: [PATCH] Just makes sure that / doesn't print when checking rwx and for wx --- swim | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/swim b/swim index 9c1a722..673c97f 100755 --- a/swim +++ b/swim @@ -818,7 +818,7 @@ sub command { print STDERR "readable" if !-r $tmp; print STDERR "/" if !-r $tmp && !-w $tmp; print STDERR "writable" if !-w $tmp; - print STDERR "/" if !-w $tmp || !-r $tmp; + print STDERR "/" if (!-w $tmp || !-r $tmp) && !-x $tmp; print STDERR "executable" if !-x $tmp; print STDERR " by your effective uid/gid\n"; @@ -826,7 +826,7 @@ sub command { print STDERR "readable" if !-r $tmp; print STDERR "/" if !-r $tmp && !-w $tmp; print STDERR "writable" if !-w $tmp; - print STDERR "/" if !-w $tmp || !-r $tmp; + print STDERR "/" if (!-w $tmp || !-r $tmp) && !-x $tmp; print STDERR "executable" if !-x $tmp; print STDERR " by your effective uid/gid " . "in $ENV{HOME}/.swim/swimrc\n"; @@ -868,7 +868,7 @@ sub command { print STDERR "readable" if !-r $tmp; print STDERR "/" if !-r $tmp && !-w $tmp; print STDERR "writable" if !-w $tmp; - print STDERR "/" if !-w $tmp || !-r $tmp; + print STDERR "/" if (!-w $tmp || !-r $tmp) && !-x $tmp; print STDERR "executable" if !-x $tmp; print STDERR " by your effective uid/gid\n"; @@ -876,7 +876,7 @@ sub command { print STDERR "readable" if !-r $tmp; print STDERR "/" if !-r $tmp && !-w $tmp; print STDERR "writable" if !-w $tmp; - print STDERR "/" if !-w $tmp || !-r $tmp; + print STDERR "/" if (!-w $tmp || !-r $tmp) && !-x $tmp; print STDERR "executable" if !-x $tmp; print STDERR " by your effective uid/gid " . "in $ENV{HOME}/.swim/swimrc\n";