summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 01c19d8)
raw | patch | inline | side by side (parent: 01c19d8)
author | Florian Forster <sifnfors@informatik.stud.uni-erlangen.de> | |
Tue, 11 Aug 2009 11:24:04 +0000 (13:24 +0200) | ||
committer | Florian Forster <sifnfors@informatik.stud.uni-erlangen.de> | |
Tue, 11 Aug 2009 11:24:04 +0000 (13:24 +0200) |
Configurations like
DisableSysfs false
are confusing.
DisableSysfs false
are confusing.
src/madwifi.c | patch | blob | history |
diff --git a/src/madwifi.c b/src/madwifi.c
index 478341ea2a1b2de2170cc9294e040d36737fcb61..364dcbd7b93d934d55c95a1ad8e36b95c09f458d 100644 (file)
--- a/src/madwifi.c
+++ b/src/madwifi.c
*
*
* By default, madwifi plugin enumerates network interfaces using /sys
- * filesystem. Configuration option DisableSysfs can change this to use
+ * filesystem. Configuration option `Source' can change this to use
* /proc filesystem (which is useful for example when running on Linux
* 2.4). But without /sys filesystem, Madwifi plugin cannot check whether
* given interface is madwifi interface and there are private ioctls used,
* which may do something completely different on non-madwifi devices.
- * Therefore, option DisableSysfs should be used together with option
- * Interface, to limit found interfaces to madwifi interfaces only.
+ * Therefore, the /proc filesystem should always be used together with option
+ * `Interface', to limit found interfaces to madwifi interfaces only.
**/
{
"Interface",
"IgnoreSelected",
- "DisableSysfs",
+ "Source",
"WatchAdd",
"WatchRemove",
"WatchSet",
else if (strcasecmp (key, "IgnoreSelected") == 0)
ignorelist_set_invert (ignorelist, ! bool_arg(value));
- else if (strcasecmp (key, "DisableSysfs") == 0)
- use_sysfs = ! bool_arg(value);
+ else if (strcasecmp (key, "Source") == 0)
+ {
+ if (strcasecmp (value, "ProcFS") == 0)
+ use_sysfs = 0;
+ else if (strcasecmp (value, "SysFS") == 0)
+ use_sysfs = 1;
+ else
+ {
+ ERROR ("madwifi plugin: The argument of the `Source' "
+ "option must either be `SysFS' or "
+ "`ProcFS'.");
+ return -1;
+ }
+ }
else if (strcasecmp (key, "WatchSet") == 0)
{