aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/_usage.h2
-rw-r--r--src/librc-misc.c16
2 files changed, 9 insertions, 9 deletions
diff --git a/src/_usage.h b/src/_usage.h
index cff60df5..f75da52e 100644
--- a/src/_usage.h
+++ b/src/_usage.h
@@ -7,7 +7,7 @@
* Released under the GPLv2
*/
-#define getoptstring_COMMON "Chq"
+#define getoptstring_COMMON "Chqv"
#define longopts_COMMON \
{ "help", 0, NULL, 'h'}, \
diff --git a/src/librc-misc.c b/src/librc-misc.c
index f2ecd165..ad144395 100644
--- a/src/librc-misc.c
+++ b/src/librc-misc.c
@@ -69,16 +69,16 @@ bool rc_env_bool (const char *var)
return (false);
}
- if (strcasecmp (var, "true") == 0 ||
- strcasecmp (var, "y") == 0 ||
- strcasecmp (var, "yes") == 0 ||
- strcasecmp (var, "1") == 0)
+ if (strcasecmp (v, "true") == 0 ||
+ strcasecmp (v, "y") == 0 ||
+ strcasecmp (v, "yes") == 0 ||
+ strcasecmp (v, "1") == 0)
return (true);
- if (strcasecmp (var, "false") != 0 &&
- strcasecmp (var, "n") != 0 &&
- strcasecmp (var, "no") != 0 &&
- strcasecmp (var, "0") != 0)
+ if (strcasecmp (v, "false") != 0 &&
+ strcasecmp (v, "n") != 0 &&
+ strcasecmp (v, "no") != 0 &&
+ strcasecmp (v, "0") != 0)
errno = EINVAL;
return (false);