| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The following test program prints "8" on 64-bit :-)
static void print_size(const char lenbuf[4])
{
printf("sizeof(lenbuf) = %d\n", (int)sizeof(lenbuf));
}
int main(void)
{
const char lenbuf[4];
print_size(lenbuf);
return 0;
}
Jeremy, please check :-)
Volker
|
|
|
|
|
| |
I think chain_reply() is one of the most tricky parts of Samba. This recursion
needs to go away, we need to sequentially walk the chain list.
|
|
|
|
|
| |
Untested code is broken code.... Test follows later, it's quite an intrusive
change to libsmb/
|
| |
|
|
|
|
|
| |
can result in a buffer overrun.
Jeremy.
|
|
|
|
| |
Jeremy.
|
| |
|
| |
|
|
|
|
|
|
|
| |
place for it now where it will cause minimal disruption (only
call the extra message_dispatch just before reading the next
smb off the wire).
Jeremy.
|
|
|
|
|
|
| |
the select return. We don't want the call to message_dispatch
to mess up the errno value.
Jeremy.
|
|
|
|
|
|
|
|
|
|
| |
using trans2 setfileinfo on one connection, and then check the
file name has changed on the other. In Samba we achieve this by
sending a local message to the other process. This change causes
us to re-scan for incoming messages after we've woken up from the
select (which is cheap if there are no pending messages). This reduces
the race significantly. Volker please review.
Jeremy.
|
|
|
|
| |
This is preparing the conversion of secrets.c to ctdb
|
|
|
|
| |
Jeremy.
|
|
|
|
| |
YESS :-)
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Jeremy.
|
|
|
|
|
|
| |
an extra parameter. This cleans up quite a few places
we were passing it around without needing it.
Jeremy.
|
|
|
|
|
|
| |
with Volker. Mostly making sure we have data on the incoming
packet type, not stored in the smb header.
Jeremy.
|
|
|
|
|
|
|
|
| |
on a share (or global) and have the server reply with
ACCESS_DENIED for all non-encrypted traffic (except
that used to query encryption requirements and set
encryption state).
Jeremy.
|
|
|
|
|
| |
negotiation works.
Jeremy.
|
|
|
|
| |
Jeremy.
|
|
|
|
| |
Jeremy.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Each cli struct has it's own local copy of this variable,
so use that in client code. In the smbd server, add one
static to smbd/proccess.c and use that inside smbd. Fix
a bunch of places where smb_rw_error could be set by
calling read_data() in places where we weren't reading
from the SMB client socket (ie. winbindd).
Jeremy.
|
|
|
|
| |
Jeremy.
|
|
|
|
|
|
| |
it may be a UNIX large writeX (which wraps len in that case).
Stevef this should fix your 128k write bug.
Jeremy.
|
|
|
|
|
|
| |
I have a plan for dealing with the remaining..... Watch
this space.
Jeremy.
|
|
|
|
| |
Jeremy.
|
|
|
|
|
| |
statics. Part of my library cleanups.
Jeremy.
|
|
|
|
|
| |
it with accessor functions. "One global or pstring a day...." :-).
Jeremy.
|
|
|
|
|
| |
not smbd/server.c
Jeremy
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
| |
bugs in various places whilst doing this (places that assumed
BOOL == int). I also need to fix the Samba4 pidl generation
(next checkin).
Jeremy.
|
| |
|
|
|
|
|
|
|
|
| |
the main server code paths. We should now be able to cope with
paths up to PATH_MAX length now.
Final job will be to add the TALLOC_CTX * parameter to
unix_convert to make it explicit (for Volker).
Jeremy.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This adds the two functions talloc_stackframe() and talloc_tos().
* When a new talloc stackframe is allocated with talloc_stackframe(), then
* the TALLOC_CTX returned with talloc_tos() is reset to that new
* frame. Whenever that stack frame is TALLOC_FREE()'ed, then the reverse
* happens: The previous talloc_tos() is restored.
*
* This API is designed to be robust in the sense that if someone forgets to
* TALLOC_FREE() a stackframe, then the next outer one correctly cleans up and
* resets the talloc_tos().
The original motivation for this patch was to get rid of the
sid_string_static & friends buffers. Explicitly passing talloc context
everywhere clutters code too much for my taste, so an implicit
talloc_tos() is introduced here. Many of these static buffers are
replaced by a single static pointer.
The intended use would thus be that low-level functions can rather
freely push stuff to talloc_tos, the upper layers clean up by freeing
the stackframe. The more of these stackframes are used and correctly
freed the more exact the memory cleanup happens.
This patch removes the main_loop_talloc_ctx, tmp_talloc_ctx and
lp_talloc_ctx (did I forget any?)
So, never do a
tmp_ctx = talloc_init("foo");
anymore, instead, use
tmp_ctx = talloc_stackframe()
:-)
Volker
|
| |
|