Repository navigation
fix: handle hyphens in bridge names and skip IFB devices (br-lan-ifb crash) - #23
Merged
Merged
Conversation
br-lan-ifb produces config_name=LAN-IFB which is invalid for shell variable names. Convert hyphens to underscores in config_name. Also skip *-ifb devices entirely since they're traffic mirroring interfaces, not QoS targets.
There was a problem hiding this comment.
🟡 Changes recommended
Setup and runtime paths still mishandle IFB devices and custom hyphenated bridge priorities.
Get a fresh assessment by requesting another Copilot review.
Pull request overview
This pull request fixes hyphenated bridge-name handling and attempts to exclude IFB devices from QoS processing.
Changes:
- Normalize hyphens in generated configuration names.
- Skip IFB devices during bridge discovery.
- Update script checksums.
Review findings:
glinet-vlan-qos-setup.sh:223— Moderate, 3 votes:write_config()still emits configuration for IFB bridges.glinet-vlan-qos-setup.sh:139— Moderate, 2 votes: custom hyphenated bridges lose their selected priority.glinet-vlan-qos.sh:117— Moderate, 3 votes: runtime enumeration paths still process IFB devices.
File summaries
| File | Summary |
|---|---|
glinet-vlan-qos.sh |
Updates bridge filtering and configuration-name handling. |
glinet-vlan-qos-setup.sh |
Updates bridge discovery and generated variable names. |
checksums.txt |
Refreshes checksums for the modified scripts. |
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 3
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+139
to
+140
| br-*) config_name=$(echo "$b" | sed 's/br-//' | tr '[:lower:]' '[:upper:]' | tr '-' '_') ;; | ||
| *) config_name=$(echo "$b" | tr '[:lower:]' '[:upper:]' | tr '-' '_') ;; |
| tailscale0|tailscale) config_name="TAILSCALE" ;; | ||
| br-*) config_name=$(echo "$br" | sed 's/br-//' | tr '[:lower:]' '[:upper:]') ;; | ||
| *) config_name=$(echo "$br" | tr '[:lower:]' '[:upper:]') ;; | ||
| br-*) config_name=$(echo "$br" | sed 's/br-//' | tr '[:lower:]' '[:upper:]' | tr '-' '_') ;; |
Comment on lines
+117
to
+120
| # Skip IFB devices (e.g., br-lan-ifb) — they're for traffic mirroring, not QoS | ||
| case "$br" in | ||
| *-ifb) continue ;; | ||
| esac |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes the
eval: PRIOR_LAN-IFB=skip: not foundcrash when the router has bridge interfaces with hyphens in their names (e.g.br-lan-ifb).Changes: