From: Olliver Schinagl Date: Wed, 21 Sep 2022 15:57:53 +0000 (+0200) Subject: base-files: Actually set default name X-Git-Tag: v23.05.0-rc1~2353 X-Git-Url: http://git.openwrt.org/?p=openwrt%2Fopenwrt.git;a=commitdiff_plain;h=211f4302e4f64e84e2895c6ed55fc1f43da56528 base-files: Actually set default name The currently used shell expansion doesn't seem to exist [0] and also does not work. This surely was not intended, so lets allow default naming to actually work. [0]: https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html Fixes: be09c5a3cd65 ("base-files: add board.d support for bridge device") Signed-off-by: Olliver Schinagl --- diff --git a/package/base-files/files/lib/functions/uci-defaults.sh b/package/base-files/files/lib/functions/uci-defaults.sh index 4f5b9634bb..86f16b5125 100644 --- a/package/base-files/files/lib/functions/uci-defaults.sh +++ b/package/base-files/files/lib/functions/uci-defaults.sh @@ -96,7 +96,7 @@ ucidef_set_interfaces_lan_wan() { ucidef_set_bridge_device() { json_select_object bridge - json_add_string name "${1:switch0}" + json_add_string name "${1:-switch0}" json_select .. }