aboutsummaryrefslogtreecommitdiff
path: root/widgets/fs.lua
diff options
context:
space:
mode:
authorJörg Thalheim <joerg@higgsboson.tk>2014-11-12 23:43:24 +0100
committerAdrian C. (anrxc) <anrxc@sysphere.org>2014-11-15 22:03:12 +0100
commit336ce9bbd7c620226d0ef01ba58c02be12f7b90e (patch)
tree5b0a621678799fcbb68add662b937087354989eb /widgets/fs.lua
parent50fd2334b6a720f798782f7690287b71642cb9a8 (diff)
downloadvicious-legacy-336ce9bbd7c620226d0ef01ba58c02be12f7b90e.tar.xz
shell escape variables before passing them to the shell
Signed-off-by: Adrian C. (anrxc) <anrxc@sysphere.org>
Diffstat (limited to 'widgets/fs.lua')
-rw-r--r--widgets/fs.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/widgets/fs.lua b/widgets/fs.lua
index 7832b1f..4b889dc 100644
--- a/widgets/fs.lua
+++ b/widgets/fs.lua
@@ -27,7 +27,7 @@ local function worker(format, warg)
if warg then warg = "" else warg = "-l" end
local fs_info = {} -- Get data from df
- local f = io.popen("LC_ALL=C df -kP " .. warg)
+ local f = io.popen("LC_ALL=C df -kP " .. helpers.shellquote(warg))
for line in f:lines() do -- Match: (size) (used)(avail)(use%) (mount)
local s = string.match(line, "^.-[%s]([%d]+)")