From: Michael Tremer Date: Sun, 10 Jun 2012 14:51:54 +0000 (+0000) Subject: Some work on making things faster. X-Git-Tag: 004~40 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=790b7ec9f9a5e42b08d730a5218bbd6d7624a69c;p=network.git Some work on making things faster. No functional changes. --- diff --git a/functions.util b/functions.util index 694c7a40..0b646f7d 100644 --- a/functions.util +++ b/functions.util @@ -75,6 +75,12 @@ function basename() { echo "${1##*/}" } +function touch() { + local file=${1} + + : > ${file} +} + function enabled() { local param=${1} @@ -82,31 +88,38 @@ function enabled() { } function mac_generate() { - local mac=() + # Get a bunch of random hex digits + # and remove all dashes from the input. + local random=$(