From a9ab7eaa5d023f0f6c2421f504f81988fd41467b Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Mon, 23 Jul 2001 22:06:05 +0000 Subject: Fix case insensitive password change code. Fixed crash bug with un-zeroed talloced memory. Jeremy. (This used to be commit eea1c30df246e081e672d7132345d0fd35ad9841) --- source3/lib/util.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'source3/lib/util.c') diff --git a/source3/lib/util.c b/source3/lib/util.c index 78e801087f..d45a805200 100644 --- a/source3/lib/util.c +++ b/source3/lib/util.c @@ -1793,7 +1793,20 @@ BOOL mask_match(char *string, char *pattern, BOOL is_case_sensitive) return ms_fnmatch(p2, s2) == 0; } +/******************************************************************* + Simple case insensitive interface to ms_fnmatch. +*******************************************************************/ + +BOOL wild_match(char *string, char *pattern) +{ + pstring p2, s2; + pstrcpy(p2, pattern); + pstrcpy(s2, string); + strlower(p2); + strlower(s2); + return ms_fnmatch(p2, s2) == 0; +} #ifdef __INSURE__ -- cgit