Imported from ../bash-2.05b.tar.gz.

This commit is contained in:
Jari Aalto 2002-07-17 14:10:11 +00:00
commit 7117c2d221
362 changed files with 34387 additions and 15063 deletions

View file

@ -30,7 +30,7 @@ hex2inet ()
do
case "$o" in
r) rev=true;;
*) echo "hex2inet: usage: hex2inet [0x]XXXXXXXX" >&2 ; exit 2;;
*) echo "hex2inet: usage: hex2inet [-r] [0x]XXXXXXXX" >&2 ; exit 2;;
esac
done
shift $(( $OPTIND - 1 ))

View file

@ -0,0 +1,14 @@
# Thanks to Chris F. A. Johnson <c.f.a.johnson@rogers.com> for this one
is_validip()
{
case "$*" in
""|*[!0-9.]*|*[!0-9]) return 1 ;;
esac
local IFS=.
set -- $*
[ $# -eq 4 ] &&
[ ${1:-666} -le 255 ] && [ ${2:-666} -le 255 ] &&
[ ${3:-666} -le 255 ] && [ ${4:-666} -le 254 ]
}

View file

@ -25,7 +25,7 @@ function manpage ()
set $file
file="$1"
if [ -f "$file" ]; then
zot=$(head -1 "$file")
zot=$(sed 1q "$file")
cmd=${MANROFF:-"nroff -man - | col | cat -s"}
h=${zot##"'"'\"'}
if [ "$h" != "$zot" ]; then

View file

@ -7,7 +7,7 @@
mhfold()
{
list=`folders | tail +2 | awk '{print $1}'`
list=`folders | awk '{if (1 < NR) print $1}'`
/bin/ls -lag ~/Mail > /tmp/fold$$
for i in $list; do
grep $i /tmp/fold$$