diff options
author | Shirish Kalele <kalele@samba.org> | 2002-05-09 04:43:05 +0000 |
---|---|---|
committer | Shirish Kalele <kalele@samba.org> | 2002-05-09 04:43:05 +0000 |
commit | 800185c33f596f071881700543f256f06b1487ac (patch) | |
tree | 0a56e7862e044dc9285c4cee008c824d8e26d342 /source3/smbd/trans2.c | |
parent | dd83af65d743f1e57c93b3788e7ab40553547622 (diff) | |
download | samba-800185c33f596f071881700543f256f06b1487ac.tar.gz samba-800185c33f596f071881700543f256f06b1487ac.tar.bz2 samba-800185c33f596f071881700543f256f06b1487ac.zip |
Sync'ing SAMBA_2_2 with HEAD.
(This used to be commit d926cc989690684ec4799ebb3a3a01e8d4173de6)
Diffstat (limited to 'source3/smbd/trans2.c')
-rw-r--r-- | source3/smbd/trans2.c | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index b46d1e930c..77cd43f04f 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -508,16 +508,23 @@ static BOOL get_lanman2_dir_entry(connection_struct *conn, continue; } } else if (vfs_stat(conn,pathreal,&sbuf) != 0) { - /* Needed to show the msdfs symlinks as directories */ - if(!lp_host_msdfs() || !lp_msdfs_root(SNUM(conn)) - || !is_msdfs_link(conn, pathreal)) { + + /* Needed to show the msdfs symlinks as + * directories */ + + if(lp_host_msdfs() && + lp_msdfs_root(SNUM(conn)) && + is_msdfs_link(conn, pathreal, NULL, NULL, + &sbuf)) { + + DEBUG(5,("get_lanman2_dir_entry: Masquerading msdfs link %s as a directory\n", pathreal)); + sbuf.st_mode = (sbuf.st_mode & 0xFFF) | S_IFDIR; + + } else { + DEBUG(5,("get_lanman2_dir_entry:Couldn't stat [%s] (%s)\n", - pathreal,strerror(errno))); + pathreal,strerror(errno))); continue; - } else { - DEBUG(5,("get_lanman2_dir_entry: Masquerading msdfs link %s as a directory\n", - pathreal)); - sbuf.st_mode = (sbuf.st_mode & 0xFFF) | S_IFDIR; } } |