summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2000-04-30 14:30:47 +0000
committerAndrew Tridgell <tridge@samba.org>2000-04-30 14:30:47 +0000
commit0f35ded18e399b2a5dfcb36d5b83368c1072fd5a (patch)
treeeefb6a022b0835e993dfdfb489dddc5cb04e741c
parent34cd425c1ded2afe5adc4d898843c31f66f26b5a (diff)
downloadsamba-0f35ded18e399b2a5dfcb36d5b83368c1072fd5a.tar.gz
samba-0f35ded18e399b2a5dfcb36d5b83368c1072fd5a.tar.bz2
samba-0f35ded18e399b2a5dfcb36d5b83368c1072fd5a.zip
go back to ascii in SMB_FIND_FILE_BOTH_DIRECTORY_INFO
NT gives out unicode, but NT clients can't handle a unicode response! (This used to be commit 85d634974f4f8841bf68cd2b22d134fbc010b568)
-rw-r--r--source3/smbd/trans2.c14
1 files changed, 4 insertions, 10 deletions
diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c
index 7ae24f9e38..458d6f3ec0 100644
--- a/source3/smbd/trans2.c
+++ b/source3/smbd/trans2.c
@@ -522,16 +522,10 @@ static BOOL get_lanman2_dir_entry(connection_struct *conn,
SIVAL(p,0,strlen(fname)); p += 4;
SIVAL(p,0,0); p += 4;
if (!was_8_3) {
- /* NT4 always uses unicode here */
- fstring short_name, ushort_name;
- int slen;
- pstrcpy(short_name,fname);
- name_map_mangle(short_name,True,True,SNUM(conn));
- strupper(short_name);
- slen = strlen(short_name);
- ascii_to_unistr(ushort_name, short_name, 24);
- memcpy(p+2, ushort_name, 2*slen);
- SSVAL(p, 0, 2*slen);
+ fstrcpy(p+2,fname);
+ name_map_mangle(p+2,True,True,SNUM(conn));
+ strupper(p+2);
+ SSVAL(p, 0, strlen(p+2));
} else {
SSVAL(p,0,0);
*(p+2) = 0;