aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xfree86/common/xf86Option.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2010-01-04 15:34:07 +0000
committermarha <marha@users.sourceforge.net>2010-01-04 15:34:07 +0000
commit33a317f48eb3fe888177235ee49b635fbb8cda2f (patch)
treeef06bc25b3a9d4096e65b8a6a11e7e8f7e7ee3c6 /xorg-server/hw/xfree86/common/xf86Option.c
parent1e723abc27bdc2ad675bce79467a7308c2966861 (diff)
downloadvcxsrv-33a317f48eb3fe888177235ee49b635fbb8cda2f.tar.gz
vcxsrv-33a317f48eb3fe888177235ee49b635fbb8cda2f.tar.bz2
vcxsrv-33a317f48eb3fe888177235ee49b635fbb8cda2f.zip
Git update 4/1/2010
Diffstat (limited to 'xorg-server/hw/xfree86/common/xf86Option.c')
-rw-r--r--xorg-server/hw/xfree86/common/xf86Option.c25
1 files changed, 2 insertions, 23 deletions
diff --git a/xorg-server/hw/xfree86/common/xf86Option.c b/xorg-server/hw/xfree86/common/xf86Option.c
index ad8d1c426..a2868bf21 100644
--- a/xorg-server/hw/xfree86/common/xf86Option.c
+++ b/xorg-server/hw/xfree86/common/xf86Option.c
@@ -42,6 +42,7 @@
#include "xf86.h"
#include "xf86Xinput.h"
#include "xf86Optrec.h"
+#include "xf86Parser.h"
static Bool ParseOptionValue(int scrnIndex, pointer options, OptionInfoPtr p,
Bool markUsed);
@@ -456,29 +457,7 @@ xf86ShowUnusedOptions(int scrnIndex, pointer options)
static Bool
GetBoolValue(OptionInfoPtr p, const char *s)
{
- if (*s == '\0') {
- p->value.bool = TRUE;
- } else {
- if (xf86NameCmp(s, "1") == 0)
- p->value.bool = TRUE;
- else if (xf86NameCmp(s, "on") == 0)
- p->value.bool = TRUE;
- else if (xf86NameCmp(s, "true") == 0)
- p->value.bool = TRUE;
- else if (xf86NameCmp(s, "yes") == 0)
- p->value.bool = TRUE;
- else if (xf86NameCmp(s, "0") == 0)
- p->value.bool = FALSE;
- else if (xf86NameCmp(s, "off") == 0)
- p->value.bool = FALSE;
- else if (xf86NameCmp(s, "false") == 0)
- p->value.bool = FALSE;
- else if (xf86NameCmp(s, "no") == 0)
- p->value.bool = FALSE;
- else
- return FALSE;
- }
- return TRUE;
+ return xf86getBoolValue(&p->value.bool, s);
}
static Bool