libs/uvl: Set an own savedir to avoid UCI problems
This commit is contained in:
parent
8f03192ce4
commit
565bc6d4c2
1 changed files with 2 additions and 2 deletions
|
@ -55,6 +55,7 @@ STRICT_LIST_TYPE = true
|
||||||
|
|
||||||
|
|
||||||
local default_schemedir = "/lib/uci/schema"
|
local default_schemedir = "/lib/uci/schema"
|
||||||
|
local default_savedir = "/tmp/.uvl"
|
||||||
local ERR = luci.uvl.errors
|
local ERR = luci.uvl.errors
|
||||||
|
|
||||||
|
|
||||||
|
@ -344,8 +345,7 @@ function UVL.read_scheme( self, scheme )
|
||||||
return so:error(ERR.SME_READ(so,file))
|
return so:error(ERR.SME_READ(so,file))
|
||||||
end
|
end
|
||||||
|
|
||||||
local uci = luci.model.uci.cursor()
|
local uci = luci.model.uci.cursor( luci.fs.dirname(file), default_savedir )
|
||||||
uci:set_confdir( luci.fs.dirname(file) )
|
|
||||||
|
|
||||||
local sd, err = uci:get_all( luci.fs.basename(file) )
|
local sd, err = uci:get_all( luci.fs.basename(file) )
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue