summaryrefslogtreecommitdiff
path: root/xserver/hw/xfree86/parser/OutputClass.c
diff options
context:
space:
mode:
Diffstat (limited to 'xserver/hw/xfree86/parser/OutputClass.c')
-rw-r--r--xserver/hw/xfree86/parser/OutputClass.c52
1 files changed, 26 insertions, 26 deletions
diff --git a/xserver/hw/xfree86/parser/OutputClass.c b/xserver/hw/xfree86/parser/OutputClass.c
index 7e9a8ac1a..3f2082ecb 100644
--- a/xserver/hw/xfree86/parser/OutputClass.c
+++ b/xserver/hw/xfree86/parser/OutputClass.c
@@ -41,6 +41,32 @@ xf86ConfigSymTabRec OutputClassTab[] = {
{-1, ""},
};
+static void
+xf86freeOutputClassList(XF86ConfOutputClassPtr ptr)
+{
+ XF86ConfOutputClassPtr prev;
+
+ while (ptr) {
+ xf86MatchGroup *group, *next;
+ char **list;
+
+ TestFree(ptr->identifier);
+ TestFree(ptr->comment);
+ TestFree(ptr->driver);
+
+ xorg_list_for_each_entry_safe(group, next, &ptr->match_driver, entry) {
+ xorg_list_del(&group->entry);
+ for (list = group->values; *list; list++)
+ free(*list);
+ free(group);
+ }
+
+ prev = ptr;
+ ptr = ptr->list.next;
+ free(prev);
+ }
+}
+
#define CLEANUP xf86freeOutputClassList
#define TOKEN_SEP "|"
@@ -139,29 +165,3 @@ xf86printOutputClassSection(FILE * cf, XF86ConfOutputClassPtr ptr)
ptr = ptr->list.next;
}
}
-
-void
-xf86freeOutputClassList(XF86ConfOutputClassPtr ptr)
-{
- XF86ConfOutputClassPtr prev;
-
- while (ptr) {
- xf86MatchGroup *group, *next;
- char **list;
-
- TestFree(ptr->identifier);
- TestFree(ptr->comment);
- TestFree(ptr->driver);
-
- xorg_list_for_each_entry_safe(group, next, &ptr->match_driver, entry) {
- xorg_list_del(&group->entry);
- for (list = group->values; *list; list++)
- free(*list);
- free(group);
- }
-
- prev = ptr;
- ptr = ptr->list.next;
- free(prev);
- }
-}