]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Don't allow the same hook to be added more than once.
authorRoy Marples <roy@marples.name>
Sat, 17 Oct 2009 06:58:42 +0000 (06:58 +0000)
committerRoy Marples <roy@marples.name>
Sat, 17 Oct 2009 06:58:42 +0000 (06:58 +0000)
configure

index 6af723ef34676be112f22e230f59b0ff0303d521..c060dc8112ed58bfaec391f25b697b650e113682 100755 (executable)
--- a/configure
+++ b/configure
@@ -322,7 +322,10 @@ for x in $HOOKSCRIPTS; do
                echo "no"
        else
                echo "$h"
-               HOOKS="$HOOKS${HOOKS:+ }$h"
+               case " $HOOKS " in
+               *" $h "*)       ;;
+               *)              HOOKS="$HOOKS${HOOKS:+ }$h";;
+               esac
        fi
 done
 cd ..