mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-14 20:37:06 +00:00
more sanity check before making output.
bark when sed fails. Submitted by: wosch@apfel.de
This commit is contained in:
parent
ef6ab9c7ee
commit
de51002fc7
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=28879
|
@ -41,8 +41,8 @@ fi
|
|||
|
||||
for i
|
||||
do
|
||||
if [ ! -e $i ]; then
|
||||
echo "$i does not exist" 1>&2
|
||||
if [ ! \( -d $i -o -r $i \) ]; then
|
||||
echo "$i inaccessible or not exist" 1>&2
|
||||
exit 66 # EX_NOINPUT
|
||||
fi
|
||||
done
|
||||
|
@ -72,7 +72,7 @@ do
|
|||
else
|
||||
echo "echo x - $i"
|
||||
echo "sed 's/^X//' >$i << 'END-of-$i'"
|
||||
sed 's/^/X/' $i
|
||||
sed 's/^/X/' $i || exit
|
||||
echo "END-of-$i"
|
||||
fi
|
||||
done
|
||||
|
|
Loading…
Reference in a new issue