]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
fix(network-legacy): silence getargs
authorHarald Hoyer <harald@redhat.com>
Mon, 8 Mar 2021 14:40:00 +0000 (15:40 +0100)
committerHarald Hoyer <harald@hoyer.xyz>
Wed, 10 Mar 2021 18:31:19 +0000 (19:31 +0100)
modules.d/35network-legacy/ifup.sh

index aae979f6f74ea0fb65f715b70f2674a653c3e19c..2aaf393af4b8721b9ea60e9ac99856b9db6d6a52 100755 (executable)
@@ -514,12 +514,12 @@ if [ -z "$NO_AUTO_DHCP" ] && [ ! -e /tmp/net.${netif}.up ]; then
         # No ip lines, no bootdev -> default to dhcp
         ip=$(getarg ip)
 
-        if getargs 'ip=dhcp6' || [ -z "$ip" -a "$netroot" = "dhcp6" ]; then
+        if getargs 'ip=dhcp6' >/dev/null || [ -z "$ip" -a "$netroot" = "dhcp6" ]; then
             load_ipv6
             do_dhcp -6
             ret=$?
         fi
-        if getargs 'ip=dhcp' || [ -z "$ip" -a "$netroot" != "dhcp6" ]; then
+        if getargs 'ip=dhcp' >/dev/null || [ -z "$ip" -a "$netroot" != "dhcp6" ]; then
             do_dhcp -4
             ret=$?
         fi