From 3931cc8bc8d36999e8ee4bd7ccfa9cb8560b8671 Mon Sep 17 00:00:00 2001 From: Antonio SJ Musumeci Date: Sun, 10 Mar 2024 17:51:45 -0500 Subject: [PATCH] func_create_ff.cpp --- src/func_create_ff.cpp | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/func_create_ff.cpp b/src/func_create_ff.cpp index 264f7570..8657175d 100644 --- a/src/func_create_ff.cpp +++ b/src/func_create_ff.cpp @@ -28,6 +28,22 @@ Func2::CreateFF::~CreateFF() namespace l { + bool + fnmatch(std::vector const &patterns_, + const char *string_) + { + int rv; + + for(auto const &pattern : patterns_) + { + rv = ::fnmatch(patterns_.c_str(),string_,FNM_EXTMATCH); + if(rv == 0) + return true; + } + + return false; + } + static int create(Branches2 &branches_,