IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an
email to Administrator. User accounts are meant only to access repo
and report issues and/or generate pull requests.
This is a purpose-specific Git hosting for
BaseALT
projects. Thank you for your understanding!
Только зарегистрированные пользователи имеют доступ к сервису!
Для получения аккаунта, обратитесь к администратору.
default_sys_recvfile() and splice() recvfile were not
written to cope with non-blocking sockets.
When either the socket read() or splice() return
-1 with errno EWOULDBLOCK or EAGAIN, if no bytes have been
processed yet, return -1 and let the caller set
blocking and retry. If bytes have been processed,
just return them as a short read and let the
caller retry with the remaining needed reads.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Now that we always require a 64 bit off_t, we no longer need SMB_OFF_T.
Andrew Bartlett
Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Fri Apr 6 01:47:43 CEST 2012 on sn-devel-104
Bug found and fix suggested by Andrew Bartlett.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Sun Dec 25 07:46:38 CET 2011 on sn-devel-104
The splice manpage explicitly requires loff_t as offset. Copy "offset" there.
Probably not required, but I wanted to make sure it's as required.
Splice blocks with large buffers. For me it worked with 16k and blocked with
32k and beyond. It would be nice to see a clarification in the manpage of
splice for this behaviour.
Splice if used with an offset increments the offset. From the manpage this was
at least not entirely obvious :-)
I haven't yet activated this (try_splice_call ist still false by default), it
needs more testing.
Volker
On a debian lenny installation with a kernel that calls itself 2.6.28, I could
repeatably block smbd using splice. According to the output of netstat, the
recvq of the TCP connection was full and at the same time according to strace
smbd was stuck in a splice syscall trying to read from that TCP connection. We
can not protect ourselves from this condition, as nobody will ever notify us
that something is broken. So sadly we can't use splice yet at all. Maybe in
2.6.29...
According to the splice(2) manpage, one of the file descriptors *must* be a
pipe. With this patch I could successfully run splice(2) on a debian lenny
installation.
Jeremy, please check!
capability for large UNIX write if not signing and
recvfile set. Cope with large UNIX write length on
incoming processing. Stevef - we can now test 1-16Mb
writes from CIFFS.
Jeremy.
(This used to be commit 8cf78776b0)
to zero). If non-zero, writeX calls greater than this
value will be left in the socket buffer for later handling
with recvfile (or userspace equivalent). Definition of
recvfile for your system is left as an exercise for
the reader (I'm working on getting splice working :-).
Jeremy.
(This used to be commit 11c03b75dd)