From af8d88d502b31623414e766d527b71fb062e1f52 Mon Sep 17 00:00:00 2001 From: Gerardo Exequiel Pozzi Date: Wed, 16 Nov 2011 02:37:39 -0300 Subject: hooks/resume: Remove cut cmd usage Signed-off-by: Gerardo Exequiel Pozzi --- hooks/resume | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'hooks/resume') diff --git a/hooks/resume b/hooks/resume index e216f42..2079e05 100644 --- a/hooks/resume +++ b/hooks/resume @@ -4,7 +4,8 @@ run_hook () if [ -n "${resume}" ]; then if [ "${resume}" != "${resume/:}" ]; then # Tux-on-ice syntax: swap:/dev/sda2 or file:/dev/sda2:0xdeadbeef - resumedev="$(echo ${resume} | cut -d: -f2)" + resumedev=${resume#*:} + resumedev=${resumedev%%:*} else # Classical syntax: just a device resumedev="${resume}" -- cgit v1.2.3-24-g4f1b