From 9a3542b80e6290f45fcba4a698a2ef0fd3260127 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Mon, 9 Sep 2002 21:06:06 +0000 Subject: Patch from Steve French to fix difference in responses to smbclient //server/share ls / on Samba and Windows 2000. Jeremy. (This used to be commit b3fe55838d23001f634f6a75f08330718353d3ad) --- source3/smbd/trans2.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'source3/smbd') diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index 8def7c0250..d21d6d2cda 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -906,7 +906,11 @@ close_if_end = %d requires_resume_key = %d level = %d, max_data_bytes = %d\n", p = strrchr_m(directory,'/'); if(p == NULL) { - pstrcpy(mask,directory); + /* Windows and OS/2 systems treat search on the root '\' as if it were '\*' */ + if((directory[0] == '.') && (directory[1] == '\0')) + pstrcpy(mask,"*"); + else + pstrcpy(mask,directory); pstrcpy(directory,"./"); } else { pstrcpy(mask,p+1); -- cgit