dav/scfg.c

branch
ucx-3.1
changeset 816
839fefbdedc7
parent 783
36a7f2ea7d12
--- a/dav/scfg.c	Sat Apr 20 13:01:58 2024 +0200
+++ b/dav/scfg.c	Thu May 23 22:35:45 2024 +0200
@@ -169,8 +169,8 @@
     CxList *exclude = cxLinkedListCreate(cxDefaultAllocator, NULL, sizeof(regex_t));
     CxList *tags = cxLinkedListCreate(cxDefaultAllocator, NULL, CX_STORE_POINTERS);
     
-    include->simple_destructor = (cx_destructor_func)regfree;
-    exclude->simple_destructor = (cx_destructor_func)regfree;
+    cxDefineDestructor(include, regfree);
+    cxDefineDestructor(exclude, regfree);
     // TODO: set tags destructor
     
     if(scfg_load_filter(node, include, exclude, tags)) {
@@ -185,7 +185,7 @@
 }
 
 void init_default_filter(Filter *filter) {
-    if(filter->include->size == 0) {
+    if(cxListSize(filter->include) == 0) {
         regex_t matchall;
         regcomp(&matchall, ".*", REG_NOSUB);
         cxListAdd(filter->include, &matchall);

mercurial