aports/main/dhcp/dhclient-script-fix-bare-ip.patch
Natanael Copa d4492c53e1 main/dhcp: use /bin/sh instead of bash in client-script
The script seems to be posix shell compatible so we only need to change
the shebang to #!/bin/sh

This way we avoid the bash dependency
2018-03-07 09:57:46 +00:00

20 lines
634 B
Diff

diff --git a/client/scripts/linux b/client/scripts/linux
index 0c42969..3214eb6 100755
--- a/client/scripts/linux
+++ b/client/scripts/linux
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
# dhclient-script for Linux. Dan Halbert, March, 1997.
# Updated for Linux 2.[12] by Brian J. Murrell, January 1999.
# No guarantees about this. I'm a novice at the details of Linux
@@ -394,7 +394,7 @@ case "$reason" in
make_resolv_conf
else
# flush all IPs from interface
- ip -4 addr flush dev ${interface}
+ ${ip} -4 addr flush dev ${interface}
exit_with_hooks 2
fi