The Samba-Bugzilla – Attachment 816 Details for
Bug 2110
CAN-2004-0930.patch breaks wildcard matching with extended characters in pattern
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch - seems to fix smbclient
look (text/plain), 1.34 KB, created by
Jeremy Allison
on 2004-12-01 17:56:38 UTC
(
hide
)
Description:
Patch - seems to fix smbclient
Filename:
MIME Type:
Creator:
Jeremy Allison
Created:
2004-12-01 17:56:38 UTC
Size:
1.34 KB
patch
obsolete
>Index: lib/ms_fnmatch.c >=================================================================== >--- lib/ms_fnmatch.c (revision 4030) >+++ lib/ms_fnmatch.c (working copy) >@@ -167,9 +167,18 @@ > } > } > >- pstrcpy_wa(p, pattern); >- pstrcpy_wa(s, string); >+ if (push_ucs2(NULL, p, pattern, sizeof(p), STR_TERMINATE) == (size_t)-1) { >+ /* Not quite the right answer, but finding the right one >+ under this failure case is expensive, and it's pretty close */ >+ return -1; >+ } > >+ if (push_ucs2(NULL, s, string, sizeof(s), STR_TERMINATE) == (size_t)-1) { >+ /* Not quite the right answer, but finding the right one >+ under this failure case is expensive, and it's pretty close */ >+ return -1; >+ } >+ > if (protocol <= PROTOCOL_LANMAN2) { > /* > for older negotiated protocols it is possible to >Index: lib/util_unistr.c >=================================================================== >--- lib/util_unistr.c (revision 4030) >+++ lib/util_unistr.c (working copy) >@@ -708,16 +708,6 @@ > The char* arguments must NOT be multibyte - to be completely sure > of this only pass string constants */ > >- >-void pstrcpy_wa(smb_ucs2_t *dest, const char *src) >-{ >- int i; >- for (i=0;i<PSTRING_LEN;i++) { >- dest[i] = UCS2_CHAR(src[i]); >- if (src[i] == 0) return; >- } >-} >- > int strcmp_wa(const smb_ucs2_t *a, const char *b) > { > while (*b && *a == UCS2_CHAR(*b)) { a++; b++; }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 2110
: 816