From 5dc7684ed187c462bcf7cfb575c86fff2584b619 Mon Sep 17 00:00:00 2001 From: Benjamin Richter Date: Wed, 17 Feb 2010 15:19:30 +0100 Subject: Use $(( )) instead of printf "%d" --- init_functions | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/init_functions b/init_functions index ec8981a..1258aff 100644 --- a/init_functions +++ b/init_functions @@ -48,8 +48,8 @@ default_mount_handler() { # It might be major/minor encoded as a single hex-number (lilo-style) (801) elif [ ${#root} -le 4 -a ${#root} -gt 2 ] && echo "${root}" | grep -qe '^[A-Fa-f0-9]*$'; then str_offset=$((${#root}-2)) - major=$(printf "%d" 0x${root:0:${str_offset}}) - minor=$(printf "%d" 0x${root:${str_offset}}) + major=$((0x${root:0:${str_offset}})) + minor=$((0x${root:${str_offset}})) rootdev="${major} ${minor}" root="/dev/root" fi -- cgit v1.2.3-24-g4f1b