Skip to content

Commit 2a3cefc

Browse files
committed
fix(fcoe-uefi): exit early on empty vlan
Exit early in case get_fcoe_boot_vlan exits with error or just an empty string, instead of producing invalid config entry.
1 parent aa20bbb commit 2a3cefc

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

modules.d/95fcoe-uefi/parse-uefifcoe.sh

+5-1
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,12 @@ print_fcoe_uefi_conf() {
1010
[ -z "$mac" ] && return 1
1111
dev=$(set_ifname fcoe "$mac")
1212
vlan=$(get_fcoe_boot_vlan "$1")
13-
if [ "$vlan" -ne "0" ]; then
13+
14+
if [ "$vlan" != "0" ]; then
1415
case "$vlan" in
16+
'')
17+
return 1
18+
;;
1519
[0-9]*)
1620
printf "%s\n" "vlan=$dev.$vlan:$dev"
1721
dev="$dev.$vlan"

0 commit comments

Comments
 (0)