1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-25 23:21:54 +03:00

Fixed Samba's wildcard algorithm to be *exactly* the same

as NT.
You do not want to know how this code works :-).
Jeremy
(This used to be commit 7adbd2dfc1)
This commit is contained in:
Jeremy Allison 1998-05-20 02:01:21 +00:00
parent 00516da27e
commit bff8dd86ee

View File

@ -678,7 +678,16 @@ static int call_trans2findfirst(char *inbuf, char *outbuf, int bufsize, int cnum
{
p = mask;
while (*p) {
if (*p == '<') *p = '*';
if (*p == '<') {
pstring expnd;
if(p[1] != '"') {
pstrcpy( expnd, p+1 );
*p++ = '*';
*p = '.';
safe_strcpy( p+1, expnd, p - mask - 1);
} else
*p = '*';
}
if (*p == '>') *p = '?';
if (*p == '"') *p = '.';
p++;