fff-babeld: Only select first list entry from router_ip #200
No reviewers
Labels
No Label
RFC
RFT
WIP
blocked
bsp
bug
build/scripts/tools
duplicate
feature
fixed
layer3
mantis
more details required
needs changes
node
packages/fff
rejected
security
trivial
upstream
No Milestone
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: freifunk-franken/firmware#200
Loading…
Reference in New Issue
No description provided.
Delete Branch "fbl/firmware:rip-fix"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The router_ip option can be a list of multiple ip addresses. It is also
possible to specify a subnet using a CIDR mask.
Only a single ip is required for peering interfaces, so select only the
first list entry and remove the CIDR mask.
Fixes: #197
While at it, use variable substitution for other CIDR mask removals as well.
@ -42,0 +41,4 @@
ip=$router_ip
# use only first ip
ip=${ip%% *}
Der nächste Befehl löscht sowieso alles ab dem ersten
/
. Richtig nötig ist die Zeile also nicht. Kann man aber zur Not auch behalten, weil es möglicherweise etwas einfacher ist zu verfolgen.Die Zeile ist nötig, denn es ist nicht erforderlich, dass die router_ip eine Netzmaske enthält.
Das uci Trennzeichen für Listen ist nunmal ein ' ', in so fern ist das auch die einzige saubere Lösung, selbst wenn ein späterer Regex aus einem vollkommen anderen Grund den gleichen Effekt hätte.
Ah! Jap, daran hab ich in dem Moment nicht gesacht.
Reviewed-by: Johannes Kimmel <fff@bareminimum.eu>
Applied.
Pull request closed