From 03387a0f5886d449eda359a5acecd830f3bd35bc Mon Sep 17 00:00:00 2001 From: Alexander Bokovoy Date: Thu, 17 Jan 2008 16:51:14 +0300 Subject: Remove is_remotestorage() call from VFS. We already have statvfs() there to handle FS capabilities. As discussed with Volker, it is better to calculate FS capabilities at connection time. We already do this with help of VFS statvfs() call which allows to fill-in system-specific attributes including FS capabilities. So just re-use it if you want to represent additional capabilities in your modules. The only caution is that you need to call underlying statvfs() call to actually get system-specific capabilities (and other fields) added. Then add module-specific ones. (This used to be commit e342ca0d931f9a5c8ec9e472dc9c63f1fe012b3a) --- source3/smbd/trans2.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'source3/smbd') diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index 5729ab5349..23d6f12996 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -2495,12 +2495,10 @@ cBytesSector=%u, cUnitTotal=%u, cUnitAvail=%d\n", (unsigned int)st.st_dev, (unsi if(lp_nt_acl_support(SNUM(conn))) { additional_flags |= FILE_PERSISTENT_ACLS; } - - if(SMB_VFS_IS_REMOTESTORAGE(conn, lp_pathname(SNUM(conn)))) { - additional_flags |= FILE_SUPPORTS_REMOTE_STORAGE; - additional_flags |= FILE_SUPPORTS_REPARSE_POINTS; - } - + + /* Capabilities are filled in at connection time through STATVFS call */ + additional_flags |= conn->fs_capabilities; + SIVAL(pdata,0,FILE_CASE_PRESERVED_NAMES|FILE_CASE_SENSITIVE_SEARCH| FILE_SUPPORTS_OBJECT_IDS|FILE_UNICODE_ON_DISK| additional_flags); /* FS ATTRIBUTES */ -- cgit