From be567f14f65eb2eee1a22fc0a2d6c03a706eeb1f Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Tue, 3 Sep 2019 15:46:10 +0200 Subject: [rootfs-stage31] Somehow fix arithmetic error --- core/rootfs/rootfs-stage31/data/inc/network.functions | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/core/rootfs/rootfs-stage31/data/inc/network.functions b/core/rootfs/rootfs-stage31/data/inc/network.functions index 94957be2..853c0cb3 100644 --- a/core/rootfs/rootfs-stage31/data/inc/network.functions +++ b/core/rootfs/rootfs-stage31/data/inc/network.functions @@ -2,9 +2,11 @@ wait_for_iface() { local DEVICE=$1 - local TIMEOUT="$(( "$2" * 2 ))" + local TIMEOUT=10 local state laststate - echo -n "Waiting for interface $DEVICE: " + [ -n "$2" ] && TIMEOUT="$2" + echo -n "Waiting ${TIMEOUT}s for interface $DEVICE: " + TIMEOUT="$(( TIMEOUT * 2 ))" # Some systems don't have operstate. Seems to be hardware dependent [ -e "/sys/class/net/${DEVICE}/operstate" ] || sleep 1 if [ -e "/sys/class/net/${DEVICE}/operstate" ]; then -- cgit v1.2.3-55-g7522