[gnome-builder/wip/lantw/fix-various-things-for-freebsd-and-clang: 3/4] foundry: don't require FNM_EXTMATCH
- From: Ting-Wei Lan <lantw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/wip/lantw/fix-various-things-for-freebsd-and-clang: 3/4] foundry: don't require FNM_EXTMATCH
- Date: Mon, 29 Jul 2019 15:37:59 +0000 (UTC)
commit ec3f94cf7430b8c4120a9a2b352a238163696bec
Author: Ting-Wei Lan <lantw src gnome org>
Date: Mon Jul 29 23:24:27 2019 +0800
foundry: don't require FNM_EXTMATCH
If the system doesn't support FNM_EXTMATCH, we just fallback to 0. It
seems to be safe because nothing depends on its extra features currently.
src/libide/foundry/ide-simple-build-system-discovery.c | 4 ++++
1 file changed, 4 insertions(+)
---
diff --git a/src/libide/foundry/ide-simple-build-system-discovery.c
b/src/libide/foundry/ide-simple-build-system-discovery.c
index c62eeb155..57883996f 100644
--- a/src/libide/foundry/ide-simple-build-system-discovery.c
+++ b/src/libide/foundry/ide-simple-build-system-discovery.c
@@ -289,7 +289,11 @@ ide_simple_build_system_discovery_match (IdeSimpleBuildSystemDiscovery *self,
g_assert (IDE_IS_SIMPLE_BUILD_SYSTEM_DISCOVERY (self));
g_assert (name != NULL);
+#ifdef FNM_EXTMATCH
return fnmatch (priv->glob, name, FNM_EXTMATCH) == 0;
+#else
+ return fnmatch (priv->glob, name, 0) == 0;
+#endif
}
static gboolean
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]