diff options
author | Andrew Tridgell <tridge@samba.org> | 2001-07-04 07:15:53 +0000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2001-07-04 07:15:53 +0000 |
commit | debb471267960e56005a741817ebd227ecfc512a (patch) | |
tree | f8c3793c025aadf809d8a8b3126c05fcd442ec70 /source/libsmb/namequery.c | |
parent | cfd81e62c81dcb114e2c9f917a01168273bf75b0 (diff) | |
download | samba-debb471267960e56005a741817ebd227ecfc512a.tar.gz samba-debb471267960e56005a741817ebd227ecfc512a.tar.xz samba-debb471267960e56005a741817ebd227ecfc512a.zip |
The big character set handling changeover!
This commit gets rid of all our old codepage handling and replaces it with
iconv. All internal strings in Samba are now in "unix" charset, which may
be multi-byte. See internals.doc and my posting to samba-technical for
a more complete explanation.
Diffstat (limited to 'source/libsmb/namequery.c')
-rw-r--r-- | source/libsmb/namequery.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/source/libsmb/namequery.c b/source/libsmb/namequery.c index 465198dfad4..18bf6f4804e 100644 --- a/source/libsmb/namequery.c +++ b/source/libsmb/namequery.c @@ -182,9 +182,7 @@ BOOL name_status_find(int type, struct in_addr to_ip, char *name) } if (i == count) return False; - StrnCpy(name, status[i].name, 15); - - dos_to_unix(name, True); + pull_ascii(name, status[i].name, 15, 0, STR_TERMINATE); free(status); return True; @@ -1025,7 +1023,8 @@ NT GETDC call, UNICODE, NT domain SID and uncle tom cobbley and all... mailslot_name = bufp; bufp += (strlen(bufp) + 1); bufp = ALIGN2(bufp, buffer); - bufp += dos_PutUniCode(bufp, srcname, sizeof(buffer) - (bufp - buffer) - 1, True); + bufp += push_ucs2(NULL, bufp, srcname, sizeof(buffer) - (bufp - buffer), STR_TERMINATE); + SIVAL(bufp,0,1); SSVAL(bufp,4,0xFFFF); SSVAL(bufp,6,0xFFFF); |