diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2008-09-01 23:42:49 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2008-09-01 23:42:49 +0000 |
commit | 730b5fad7a42e1d51b7ea2a59a500342ff4ff2bf (patch) | |
tree | 37a688bac835904e39c46374d3a79aca282124c0 /contrib/package/olsrd-luci/files | |
parent | 92e315d3277fb0f51b60bd06ef5f95f00b51e1f3 (diff) |
* luci/contrib: olsrd-luci: only write sections for existing plugins, change default interface to br-lan
Diffstat (limited to 'contrib/package/olsrd-luci/files')
-rw-r--r-- | contrib/package/olsrd-luci/files/etc/config/olsr | 2 | ||||
-rw-r--r-- | contrib/package/olsrd-luci/files/lib/config/olsr.lua | 7 |
2 files changed, 6 insertions, 3 deletions
diff --git a/contrib/package/olsrd-luci/files/etc/config/olsr b/contrib/package/olsrd-luci/files/etc/config/olsr index a1fe65aa7c..5361b7081c 100644 --- a/contrib/package/olsrd-luci/files/etc/config/olsr +++ b/contrib/package/olsrd-luci/files/etc/config/olsr @@ -34,7 +34,7 @@ config 'Interface' option 'TcValidityTime' '324.0' option 'HnaInterval' '18.0' option 'MidInterval' '18.0' - option 'Interface' 'br-ff' + option 'Interface' 'br-lan' config 'ipc' 'IpcConnect' option 'MaxConnections' '0' diff --git a/contrib/package/olsrd-luci/files/lib/config/olsr.lua b/contrib/package/olsrd-luci/files/lib/config/olsr.lua index d444e4d7c6..a10837ff46 100644 --- a/contrib/package/olsrd-luci/files/lib/config/olsr.lua +++ b/contrib/package/olsrd-luci/files/lib/config/olsr.lua @@ -15,6 +15,7 @@ $Id$ ]]-- +require("luci.fs") require("luci.util") require("luci.model.uci") @@ -57,7 +58,7 @@ local function _section(sect,sval,parstr) if sval then rv = rv .. "}\n" - end + end return rv end @@ -118,7 +119,9 @@ print( _section("general") ) -- plugin config sections for k, v in luci.util.spairs(conf) do if conf[k][".type"] == "LoadPlugin" then - print( _section( k, "Library", "PlParam" ) ) + if v.Library and luci.fs.access("/usr/lib/"..v.Library) then + print( _section( k, "Library", "PlParam" ) ) + end end end |