2013.11.07. 17:23 keltezéssel, Daniel Gimpelevich írta:
> The mtd_get_mac_ascii utility function was broken. This fixes it.
>
> Signed-off-by: Daniel Gimpelevich <[email protected]>
> Index: package/base-files/files/lib/functions.sh
> ===================================================================
> --- a/package/base-files/files/lib/functions.sh (revision 38679)
> +++ b/package/base-files/files/lib/functions.sh (working copy)
> @@ -248,15 +248,13 @@
> local part
> local mac_dirty
>
> - . /lib/functions.sh
> -
> part=$(find_mtd_part "$mtdname")
> if [ -z "$part" ]; then
> echo "mtd_get_mac_ascii: partition $mtdname not found!" >&2
> return
> fi
>
> - mac_dirty=$(strings "$part" | sed -n 's/'"$key"'=//p')
> + mac_dirty=$(strings "$part" | sed -n 's/^'"$key"'=//p')
> # "canonicalize" mac
> printf "%02x:%02x:%02x:%02x:%02x:%02x" 0x${mac_dirty//:/ 0x}
> }
> _______________________________________________
> openwrt-devel mailing list
> [email protected]
> https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
>
_______________________________________________
openwrt-devel mailing list
[email protected]
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel