From cd0973a87d41a7a90808024861aff1af4d4d3096 Mon Sep 17 00:00:00 2001 From: Thomas Bächler Date: Tue, 12 Jan 2010 21:18:57 +0100 Subject: Replace the custom 'replace' tool with 'sed' --- load-modules.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'load-modules.sh') diff --git a/load-modules.sh b/load-modules.sh index 21767ca..f703088 100755 --- a/load-modules.sh +++ b/load-modules.sh @@ -7,7 +7,7 @@ MODPROBE="/sbin/modprobe" RESOLVEALIAS="/bin/resolve-modalias" USEBLACKLIST="--use-blacklist" -REPLACE="/bin/replace" +SED="/bin/sed" MODDEPS="/bin/moddeps" if [ -f /proc/cmdline ]; then @@ -19,12 +19,12 @@ if [ -f /proc/cmdline ]; then done #parse cmdline entries of the form "disablemodules=x,y,z" if [ -n "${disablemodules}" ]; then - BLACKLIST="$(${REPLACE} ${disablemodules} ',')" + BLACKLIST="$(echo "${disablemodules}" | ${SED} 's|,| |g')" fi fi # sanitize the module names -BLACKLIST="$(${REPLACE} "${BLACKLIST}" '-' '_')" +BLACKLIST="$(echo "${BLACKLIST}" | ${SED} 's|-|_|g')" if [ -n "${BLACKLIST}" ] ; then # Try to find all modules for the alias -- cgit v1.2.3-24-g4f1b