git.samba.org
/
amitay
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f452de7
)
Fixed wildcard match bug with '****' with smbclient. Found by Andrew (damn him! :-).
author
Jeremy Allison
<jra@samba.org>
Wed, 9 Feb 2000 15:50:44 +0000
(15:50 +0000)
committer
Jeremy Allison
<jra@samba.org>
Wed, 9 Feb 2000 15:50:44 +0000
(15:50 +0000)
Jeremy.
(This used to be commit
c8ca70f99ee2eae5e29ddf0dd4bc231fbcd188f2
)
source3/lib/util.c
patch
|
blob
|
history
diff --git
a/source3/lib/util.c
b/source3/lib/util.c
index a824887e88b76cb5696fcf436e766b0743472c9c..564fc8822227537049523b533bd27424e86d4f49 100644
(file)
--- a/
source3/lib/util.c
+++ b/
source3/lib/util.c
@@
-1321,8
+1321,9
@@
BOOL mask_match(char *str, char *regexp, BOOL case_sig, BOOL trans2)
#endif
/* Remove any *? and ** as they are meaningless */
- pstring_sub(t_pattern, "*?", "*");
- pstring_sub(t_pattern, "**", "*");
+ for(p = t_pattern; *p; p++)
+ while( *p == '*' && (p[1] == '?' || p[1] == '*'))
+ (void)pstrcpy( &p[1], &p[2]);
if (strequal(t_pattern,"*"))
return(True);