summaryrefslogtreecommitdiffhomepage
path: root/src/ffluci/model/uci.lua
diff options
context:
space:
mode:
authorSteven Barth <steven@midlink.org>2008-03-30 19:25:31 +0000
committerSteven Barth <steven@midlink.org>2008-03-30 19:25:31 +0000
commit1bf67dcd798e6edc859e74c77b194928d7f63fbe (patch)
tree8df67a3ac9228a72daac8149d16c075ad9686038 /src/ffluci/model/uci.lua
parent9b4e269bea4db2e75d3d33757a53d2ab89bf05bf (diff)
* Moved exec, execl from ffluci.util to ffluci.sys
* Introduced stub for ffluci.model.ipkg
Diffstat (limited to 'src/ffluci/model/uci.lua')
-rw-r--r--src/ffluci/model/uci.lua7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/ffluci/model/uci.lua b/src/ffluci/model/uci.lua
index 6585c66cb4..94a385c7e1 100644
--- a/src/ffluci/model/uci.lua
+++ b/src/ffluci/model/uci.lua
@@ -32,6 +32,7 @@ limitations under the License.
module("ffluci.model.uci", package.seeall)
require("ffluci.util")
require("ffluci.fs")
+require("ffluci.sys")
-- The OS uci command
ucicmd = "uci"
@@ -135,7 +136,7 @@ end
-- Internal functions --
function Session._uci(self, cmd)
- local res = ffluci.util.exec(self.ucicmd .. " 2>/dev/null " .. cmd)
+ local res = ffluci.sys.exec(self.ucicmd .. " 2>/dev/null " .. cmd)
if res:len() == 0 then
return nil
@@ -145,7 +146,7 @@ function Session._uci(self, cmd)
end
function Session._uci2(self, cmd)
- local res = ffluci.util.exec(self.ucicmd .. " 2>&1 " .. cmd)
+ local res = ffluci.sys.exec(self.ucicmd .. " 2>&1 " .. cmd)
if res:len() > 0 then
return false, res
@@ -155,7 +156,7 @@ function Session._uci2(self, cmd)
end
function Session._uci3(self, cmd)
- local res = ffluci.util.execl(self.ucicmd .. " 2>&1 " .. cmd)
+ local res = ffluci.sys.execl(self.ucicmd .. " 2>&1 " .. cmd)
if res[1]:sub(1, ucicmd:len() + 1) == ucicmd .. ":" then
return nil, res[1]
end