aboutsummaryrefslogtreecommitdiff
path: root/lib/cleanpath.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/cleanpath.c')
-rw-r--r--lib/cleanpath.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/cleanpath.c b/lib/cleanpath.c
index d1c9637..ab6525b 100644
--- a/lib/cleanpath.c
+++ b/lib/cleanpath.c
@@ -62,8 +62,10 @@ struct CleanPath *cleanpath_init(const char *path, const char *sep) {
* @note CLEANPATH_FILTER_EXACT is the default mode
*/
void cleanpath_filter(struct CleanPath *path, unsigned mode, const char *pattern) {
- int match;
+#if !OS_WINDOWS
regex_t regex;
+#endif
+ int match;
for (size_t i = 0; path->part[i]; i++) {
match = 0;