#
# CDDL HEADER START
#
# The contents of this file are subject to the terms of the
# Common Development and Distribution License (the "License").
# You may not use this file except in compliance with the License.
#
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
# See the License for the specific language governing permissions
# and limitations under the License.
#
# When distributing Covered Code, include this CDDL HEADER in each
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
# If applicable, add the following below this CDDL HEADER, with the
# fields enclosed by brackets "[]" replaced with your own identifying
# information: Portions Copyright [yyyy] [name of copyright owner]
#
# CDDL HEADER END
#
#
#
export PKGINST
if [ ! -x $irbac ]
then
echo "${irbac}: not found."
exit $SMF_EXIT_ERR_FATAL
fi
case "$1" in
;;
stop)
exit $SMF_EXIT_OK;;
*)
echo "Usage: $0 { start | refresh | stop }"
exit $SMF_EXIT_ERR_FATAL;;
esac
if [ -z "$tmp_rbac" ]
then
echo "Could not create temporary directory."
exit $SMF_EXIT_ERR_FATAL
fi
do
d=${f}.d
if [ ! -d ${d} ]
then
# No directory, nothing to do
continue
fi
#
# List all the files in the directory and the destination file
# in the order of their timestamp. Older files are displayed
# first. If a fragment file is listed before the destination
# file, it is an older fragment that has already been processed.
# If a fragment file is listed after the destination file, it is
# new, and the destination file must be updated.
#
# Comments are processed separately from the other file contents.
# For new fragments only, the comments are processed as they are
# encountered. For all fragments, the non-comment contents are
# saved in a temporary file. After all fragments have been
# processed, and only if new fragments were found, the contents
# of the temporary file are processed. This ensures that older
# but still valid entries are retained in the destination file.
#
new_frag=0
update=0
do
if [ "$frag" = "$f" ]
then
new_frag=1
continue
fi
if [ -f "$frag" ]
then
then
update=1
fi
fi
done
then
chown $ownergroup $f
fi
done
exit $SMF_EXIT_OK