base-files: strip quotes from the MAC address in macaddr_canonicalize()
authorGabor Juhos <juhosg@openwrt.org>
Mon, 14 Jul 2014 10:25:49 +0000 (10:25 +0000)
committerGabor Juhos <juhosg@openwrt.org>
Mon, 14 Jul 2014 10:25:49 +0000 (10:25 +0000)
Extracted from http://patchwork.openwrt.org/patch/5716/

Signed-off-by: Forest Crossman <cyrozap@gmail.com>
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
SVN-Revision: 41639

package/base-files/files/lib/functions/system.sh

index a4c0f2620c5e9179b5033a4c5a4ecf8d34d31a5c..8d75a5a8ce620faa952b6a2d760ad8f32dff397e 100644 (file)
@@ -82,6 +82,7 @@ macaddr_canonicalize()
        local mac="$1"
        local canon=""
 
+       mac=$(echo -n $mac | tr -d \")
        [ ${#mac} -gt 17 ] && return
        [ -n "${mac//[a-fA-F0-9\.: -]/}" ] && return