]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
If cmp and diff aren't around, try a text match using cat. After all, we are working...
authorRoy Marples <roy@marples.name>
Fri, 15 Aug 2008 11:33:33 +0000 (11:33 +0000)
committerRoy Marples <roy@marples.name>
Fri, 15 Aug 2008 11:33:33 +0000 (11:33 +0000)
dhcpcd-run-hooks.in

index 6619294299c27d0a35b4ac43f031562bb9c1c040..1e5d5b374be6fe3694a037f44efb4e23b4b585ad 100644 (file)
@@ -87,7 +87,8 @@ change_file()
        elif type diff >/dev/null 2>&1; then
                diff -q "$1" "$2" >/dev/null
        else
-               false
+               # Hopefully we're only working on small text files ...
+               [ "$(cat "$1")" = "$(cat "$2")" ]
        fi
        if [ $? -eq 0 ]; then
                rm -f "$2"