switchToWatchXid(): modified the new migrate-path to work when there exists a process...
[util-vserver.git] / util-vserver / lib_internal / matchlist.h
index 0cbf907..d06e7bd 100644 (file)
 #include <stdbool.h>
 
 typedef int    (*MatchItemCompareFunc)(char const *, char const *);
+typedef enum { stINCLUDE,stEXCLUDE,stSKIP }    MatchType;
 
 struct MatchItem
 {
-    enum { stINCLUDE, stEXCLUDE }      type;
-    char const *                       name;
-    MatchItemCompareFunc               cmp;
+    MatchType                  type;
+    char const *               name;
+    MatchItemCompareFunc       cmp;
 };
 
 struct MatchList
@@ -62,10 +63,12 @@ void                MatchList_appendFiles(struct MatchList *, size_t idx,
                                      char **files, size_t count,
                                      bool auto_type) NONNULL((1,3));
 
-bool           MatchList_compare(struct MatchList const *,
+MatchType      MatchList_compare(struct MatchList const *,
                                  char const *path) NONNULL((1,2));
 struct MatchItem
 const *                MatchList_find(struct MatchList const *,
                               char const *path) NONNULL((1,2));
 
+void           MatchList_printId(struct MatchList const *, int fd) NONNULL((1));
+
 #endif //  H_UTIL_VSERVER_LIB_INTERNAL_MATCHLIST_H