summaryrefslogtreecommitdiff
path: root/source4/smb_server
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2006-10-28 06:06:15 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:24:40 -0500
commit9cd2b012f3bf9f21f321d44c43eb5a8a781d68fc (patch)
tree6bfe7a5af735a980f8a8d120d60f3326ac8e7d5a /source4/smb_server
parent863bd921f26f95523674de325e520ae2523df3a9 (diff)
downloadsamba-9cd2b012f3bf9f21f321d44c43eb5a8a781d68fc.tar.gz
samba-9cd2b012f3bf9f21f321d44c43eb5a8a781d68fc.tar.bz2
samba-9cd2b012f3bf9f21f321d44c43eb5a8a781d68fc.zip
r19504: - fixed a free error in file_lines_parse
- added a function to test for large file support - enable CAP_LARGE_FILES only if the test passes - don't test at large offsets if the server doesn't set CAP_LARGE_FILES (This used to be commit c5423ea22bdaa055807d4e6f7ac4be934194fe45)
Diffstat (limited to 'source4/smb_server')
-rw-r--r--source4/smb_server/smb/negprot.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/source4/smb_server/smb/negprot.c b/source4/smb_server/smb/negprot.c
index 25684bee27..4aecca53ba 100644
--- a/source4/smb_server/smb/negprot.c
+++ b/source4/smb_server/smb/negprot.c
@@ -250,6 +250,7 @@ static void reply_nt1(struct smbsrv_request *req, uint16_t choice)
time_t t = req->request_time.tv_sec;
NTTIME nttime;
BOOL negotiate_spnego = False;
+ char *large_test_path;
unix_to_nt_time(&nttime, t);
@@ -277,8 +278,11 @@ static void reply_nt1(struct smbsrv_request *req, uint16_t choice)
if (lp_large_readwrite()) {
capabilities |= CAP_LARGE_READX | CAP_LARGE_WRITEX | CAP_W2K_SMBS;
}
-
- capabilities |= CAP_LARGE_FILES;
+
+ large_test_path = lock_path(req, "large_test.dat");
+ if (large_file_support(large_test_path)) {
+ capabilities |= CAP_LARGE_FILES;
+ }
if (lp_readraw() && lp_writeraw()) {
capabilities |= CAP_RAW_MODE;