From 5c3fbfd733536f792d01f062a43cc4f785a2794c Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Wed, 4 May 2011 11:21:03 -0400 Subject: [PATCH] Don't let the fnmatch/glob macros expand the function prototype. --- compat/fnmatch.h | 4 ++-- compat/glob.h | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/compat/fnmatch.h b/compat/fnmatch.h index 2c310796d..b7504ce46 100644 --- a/compat/fnmatch.h +++ b/compat/fnmatch.h @@ -41,8 +41,8 @@ #define FNM_LEADING_DIR 0x08 /* Ignore / after Imatch. */ #define FNM_CASEFOLD 0x10 /* Case insensitive search. */ -#define fnmatch(_a, _b, _c) rpl_fnmatch((_a), (_b), (_c)) +int rpl_fnmatch(const char *, const char *, int); -int fnmatch(const char *, const char *, int); +#define fnmatch(_a, _b, _c) rpl_fnmatch((_a), (_b), (_c)) #endif /* !_FNMATCH_H_ */ diff --git a/compat/glob.h b/compat/glob.h index 8279b796c..7e7153b30 100644 --- a/compat/glob.h +++ b/compat/glob.h @@ -69,10 +69,10 @@ typedef struct { #define GLOB_NOSYS (-4) /* Function not supported. */ #define GLOB_ABEND GLOB_ABORTED +int rpl_glob(const char *, int, int (*)(const char *, int), glob_t *); +void rpl_globfree(glob_t *); + #define glob(_a, _b, _c, _d) rpl_glob((_a), (_b), (_c), (_d)) #define globfree(_a) rpl_globfree((_a)) -int glob(const char *, int, int (*)(const char *, int), glob_t *); -void globfree(glob_t *); - #endif /* !_GLOB_H_ */ -- 2.50.1