From 1bfc3bae68ac72ab3bf1754984cc8c6d7d5a247e Mon Sep 17 00:00:00 2001 From: =?utf8?q?Andre=20Kl=C3=A4rner?= Date: Thu, 10 Apr 2014 12:28:20 +0200 Subject: [PATCH 1/1] ask df for a specific filesystem POSIX df supports requesting a single filesystem, so doing so will ensure that df can only get stuck if the filesystem we requested is in a hung state. --- widgets/fs.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/widgets/fs.lua b/widgets/fs.lua index 7406e05..4d9d278 100644 --- a/widgets/fs.lua +++ b/widgets/fs.lua @@ -67,7 +67,7 @@ local function worker(args) fs_info = {} fs_now = {} - local f = io.popen("LC_ALL=C df -kP") + local f = io.popen("LC_ALL=C df -kP " .. partition) for line in f:lines() do -- Match: (size) (used)(avail)(use%) (mount) local s = string.match(line, "^.-[%s]([%d]+)") -- 2.39.5