The Samba-Bugzilla – Attachment 13757 Details for
Bug 13119
Return NT_STATUS_FILE_SYSTEM_LIMITATION stream IO runs into fs limit
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
WIP patch for master
wip (text/plain), 1.37 KB, created by
Ralph Böhme
on 2017-11-06 10:15:48 UTC
(
hide
)
Description:
WIP patch for master
Filename:
MIME Type:
Creator:
Ralph Böhme
Created:
2017-11-06 10:15:48 UTC
Size:
1.37 KB
patch
obsolete
>From 8b32e62d35efbd634fb80fdada0da7f7fac9a66d Mon Sep 17 00:00:00 2001 >From: Ralph Boehme <slow@samba.org> >Date: Mon, 6 Nov 2017 11:09:44 +0100 >Subject: [PATCH] WIP: s3/smbd: max xattr xize in get_ea_value() > >The current maximum allowed xattr size is 64 KB which is too small for >certain use cases. > >Raise this limit to 64 MB by adding a parametric option >"smbd:max_xattr_size" with a default value of 64 MB. > >The option value is stored in a static value to avoid expensive calls to >loadparm for every call to get_ea_value(). >--- > source3/smbd/trans2.c | 10 ++++++++-- > 1 file changed, 8 insertions(+), 2 deletions(-) > >diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c >index de6073a973f..483739868e6 100644 >--- a/source3/smbd/trans2.c >+++ b/source3/smbd/trans2.c >@@ -214,6 +214,12 @@ NTSTATUS get_ea_value(TALLOC_CTX *mem_ctx, > size_t attr_size = 256; > char *val = NULL; > ssize_t sizeret; >+ static size_t max_xattr_size = 0; >+ >+ if (max_xattr_size == 0) { >+ max_xattr_size = (size_t)lp_parm_ulonglong( >+ SNUM(conn), "smbd", "max_xattr_size", 64*1024*1024); >+ } > > again: > >@@ -229,8 +235,8 @@ NTSTATUS get_ea_value(TALLOC_CTX *mem_ctx, > ea_name, val, attr_size); > } > >- if (sizeret == -1 && errno == ERANGE && attr_size != 65536) { >- attr_size = 65536; >+ if (sizeret == -1 && errno == ERANGE && attr_size <= max_xattr_size) { >+ attr_size = sizeret; > goto again; > } > >-- >2.13.6 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 13119
: 13757