diff options
Diffstat (limited to 'hw/xfree86/parser/Module.c')
-rw-r--r-- | hw/xfree86/parser/Module.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/hw/xfree86/parser/Module.c b/hw/xfree86/parser/Module.c index 81eff18ae..2012ce6d2 100644 --- a/hw/xfree86/parser/Module.c +++ b/hw/xfree86/parser/Module.c @@ -76,6 +76,7 @@ static xf86ConfigSymTabRec ModuleTab[] = { {ENDSECTION, "endsection"}, {LOAD, "load"}, + {DISABLE, "disable"}, {LOAD_DRIVER, "loaddriver"}, {SUBSECTION, "subsection"}, {-1, ""}, @@ -141,6 +142,13 @@ xf86parseModuleSection (void) xf86addNewLoadDirective (ptr->mod_load_lst, val.str, XF86_LOAD_MODULE, NULL); break; + case DISABLE: + if (xf86getSubToken (&(ptr->mod_comment)) != STRING) + Error (QUOTE_MSG, "Disable"); + ptr->mod_disable_lst = + xf86addNewLoadDirective (ptr->mod_disable_lst, val.str, + XF86_DISABLE_MODULE, NULL); + break; case LOAD_DRIVER: if (xf86getSubToken (&(ptr->mod_comment)) != STRING) Error (QUOTE_MSG, "LoadDriver"); @@ -257,6 +265,15 @@ xf86freeModules (XF86ConfModulePtr ptr) lptr = lptr->list.next; xf86conffree (prev); } + lptr = ptr->mod_disable_lst; + while (lptr) + { + TestFree (lptr->load_name); + TestFree (lptr->load_comment); + prev = lptr; + lptr = lptr->list.next; + xf86conffree (prev); + } TestFree (ptr->mod_comment); xf86conffree (ptr); } |