mirror of
https://github.com/Telecominfraproject/wlan-ap.git
synced 2025-10-29 09:32:34 +00:00
rtty: fix init script error handling
Fix variable quoting in test conditions and remove explicit stderr redirects to improve error message handling and prevent boot log spam. Signed-off-by: John Crispin <john@phrozen.org>
This commit is contained in:
@@ -25,21 +25,21 @@ start_rtty() {
|
||||
local ifname
|
||||
|
||||
[ "$2" = 0 ] || {
|
||||
echo "validation failed" >&2
|
||||
echo "validation failed"
|
||||
return 1
|
||||
}
|
||||
|
||||
[ $enable -eq 0 -a $interval -eq 0 ] && return 1
|
||||
[ "$enable" -eq 0 -a "$interval" -eq 0 ] && return 1
|
||||
|
||||
[ -n "$interface" ] && network_get_device ifname "$interface"
|
||||
|
||||
[ -z "$ifname" -a -z "$id" ] && {
|
||||
echo "You must specify an interface or ID" >&2
|
||||
echo "You must specify an interface or ID"
|
||||
return 1
|
||||
}
|
||||
|
||||
[ -z "$host" ] && {
|
||||
echo "host required" >&2
|
||||
echo "host required"
|
||||
return 1
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user