2
0
mirror of https://gitlab.isc.org/isc-projects/dhcp synced 2025-09-03 07:45:20 +00:00

Use -f instead of -x to look for hooks.

This commit is contained in:
Ted Lemon
2001-04-20 20:01:19 +00:00
parent 61aaca12d9
commit 06fa897b5e
6 changed files with 12 additions and 12 deletions

View File

@@ -32,7 +32,7 @@ function make_resolv_conf() {
# Must be used on exit. Invokes the local dhcp client exit hooks, if any.
function exit_with_hooks() {
exit_status=$1
if [ -x /etc/dhclient-exit-hooks ]; then
if [ -f /etc/dhclient-exit-hooks ]; then
. /etc/dhclient-exit-hooks
fi
# probably should do something with exit status of the local script
@@ -40,7 +40,7 @@ function exit_with_hooks() {
}
# Invoke the local dhcp client enter hooks, if they exist.
if [ -x /etc/dhclient-enter-hooks ]; then
if [ -f /etc/dhclient-enter-hooks ]; then
exit_status=0
. /etc/dhclient-enter-hooks
# allow the local script to abort processing of this state