projects
/
15.05
/
openwrt.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f9a7a43
)
netifd: add missing do_sysctl function
author
Felix Fietkau
<nbd@openwrt.org>
Mon, 27 Feb 2012 23:37:46 +0000
(23:37 +0000)
committer
Felix Fietkau
<nbd@openwrt.org>
Mon, 27 Feb 2012 23:37:46 +0000
(23:37 +0000)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@30749
3c298f89
-4303-0410-b956-
a3cf2f4a3e73
package/netifd/files/lib/network/config.sh
patch
|
blob
|
history
diff --git
a/package/netifd/files/lib/network/config.sh
b/package/netifd/files/lib/network/config.sh
index
ab3efe8
..
129cb66
100755
(executable)
--- a/
package/netifd/files/lib/network/config.sh
+++ b/
package/netifd/files/lib/network/config.sh
@@
-57,3
+57,8
@@
setup_interface() {
ubus call network.interface."$config" add_device "{ \"name\": \"$iface\" }"
}
+do_sysctl() {
+ [ -n "$2" ] && \
+ sysctl -n -e -w "$1=$2" >/dev/null || \
+ sysctl -n -e "$1"
+}