diff options
author | Stefan Metzmacher <metze@samba.org> | 2013-09-27 05:44:33 +0200 |
---|---|---|
committer | Karolin Seeger <kseeger@samba.org> | 2014-03-10 16:12:19 +0100 |
commit | c35d8a3d12ad57169916972d4bdcdecaa451ead2 (patch) | |
tree | 903a8bb79ea785fef1b78121d11234530c6320be /source3/libsmb/libsmb_stat.c | |
parent | e55b6fb64e456808a407d900d4f599be3111595f (diff) | |
download | samba-c35d8a3d12ad57169916972d4bdcdecaa451ead2.tar.gz |
s3/libsmb: make use of smbXcli_tcon_is_dfs_share()
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 37f0e3722cea3ff433d2c95d697e38693c676ae0)
Diffstat (limited to 'source3/libsmb/libsmb_stat.c')
-rw-r--r-- | source3/libsmb/libsmb_stat.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/source3/libsmb/libsmb_stat.c b/source3/libsmb/libsmb_stat.c index dc59f9cc82f..94449e0d86a 100644 --- a/source3/libsmb/libsmb_stat.c +++ b/source3/libsmb/libsmb_stat.c @@ -364,6 +364,13 @@ SMBC_fstatvfs_ctx(SMBCCTX *context, unsigned long flags = 0; uint32 fs_attrs = 0; struct cli_state *cli = file->srv->cli; + struct smbXcli_tcon *tcon; + + if (smbXcli_conn_protocol(cli->conn) >= PROTOCOL_SMB2_02) { + tcon = cli->smb2.tcon; + } else { + tcon = cli->smb1.tcon; + } /* Initialize all fields (at least until we actually use them) */ memset(st, 0, sizeof(*st)); @@ -469,7 +476,9 @@ SMBC_fstatvfs_ctx(SMBCCTX *context, } /* See if DFS is supported */ - if (smbXcli_conn_dfs_supported(cli->conn) && cli->dfsroot) { + if (smbXcli_conn_dfs_supported(cli->conn) && + smbXcli_tcon_is_dfs_share(tcon)) + { flags |= SMBC_VFS_FEATURE_DFS; } |