[projects/setup] profile: skip reading /etc/env.d non-files (dirs)
glen
glen at pld-linux.org
Mon Apr 7 16:32:01 CEST 2014
commit ffb20e9b23f3db91c33ffdb3af5c2197d8bf877a
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Mon Apr 7 17:31:56 2014 +0300
profile: skip reading /etc/env.d non-files (dirs)
etc/profile | 3 +++
1 file changed, 3 insertions(+)
---
diff --git a/etc/profile b/etc/profile
index fd4c7f2..718ff21 100644
--- a/etc/profile
+++ b/etc/profile
@@ -119,6 +119,9 @@ if [ -f /etc/profile.env ]; then
. /etc/profile.env
else
for i in /etc/env.d/* ; do
+ # skip not-regular files
+ test -f "$i" || continue
+
NAME=${i##*/}
case $NAME in
*~ | *.bak | *.old | *.rpmnew | *.rpmsave | *.zwc )
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/projects/setup.git/commitdiff/ffb20e9b23f3db91c33ffdb3af5c2197d8bf877a
More information about the pld-cvs-commit
mailing list