Skip to content
Browse files

relayd: add uci validation

Signed-off-by: John Crispin <blogic@openwrt.org>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@39623 3c298f89-4303-0410-b956-a3cf2f4a3e73
  • Loading branch information...
1 parent cb87eac commit 91677682e11ef3452c2da229282bbc13791174a6 blogic committed Feb 18, 2014
Showing with 13 additions and 0 deletions.
  1. +13 −0 package/network/services/relayd/files/relay.init
View
13 package/network/services/relayd/files/relay.init
@@ -6,6 +6,19 @@ START=80
USE_PROCD=1
PROG=/usr/sbin/relayd
+validate_proto_relayd()
+{
+ uci_validate_section network "interface" "${1}" \
+ 'network:list(string)' \
+ 'expiry:uinteger:30' \
+ 'retry:uinteger:5' \
+ 'table:range(0, 65535):16800' \
+ 'forward_bcast:bool:1' \
+ 'forward_dhcp:bool:1'
+
+ return $?
+}
+
resolve_ifname() {
grep -qs "^ *$1:" /proc/net/dev && {
procd_append_param command -I "$1"

0 comments on commit 9167768

Please sign in to comment.
Something went wrong with that request. Please try again.