From e8a14f7ca2fafb4be247c1c25a72ef30cfb6e5f6 Mon Sep 17 00:00:00 2001 From: octo Date: Sat, 28 Jan 2006 10:46:11 +0000 Subject: [PATCH] The ACPI code in the `battery' plugin now ignores `dirent's that begin with a dot `.'. --- src/battery.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/battery.c b/src/battery.c index 123a05ac..541bab3d 100644 --- a/src/battery.c +++ b/src/battery.c @@ -256,6 +256,9 @@ static void battery_read (void) while ((ent = readdir (dh)) != NULL) { + if (ent->d_name[0] == '.') + continue; + len = snprintf (filename, BUFSIZE, "/proc/acpi/battery/%s/state", ent->d_name); if ((len >= BUFSIZE) || (len < 0)) continue; -- 2.30.2