| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Jeremy.
(cherry picked from commit 44ab658b6d80c66f20d80aede7fc7cd2b9a941b1)
|
|
|
|
|
|
| |
Wrap lines and remove trailing space.
Michael
|
|
|
|
|
|
| |
The errno is handed up through the VFS layer to the callers.
Michael
|
|
|
|
|
|
|
|
| |
Now that it is inside the vfs layer, this function should
not alter the fsp (i.e. set fsp->fh->fd = -1) anymore.
That belongs above the vfs layer.
Michael
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This hides the pending close fds from the outside. Call order
of SMB_VFS_CLOSE is reversed. Originally, it was:
fd_close -> fd_close_posix -> SMB_VFS_CLOSE -> close
And now it is:
fd_close -> SMB_VFS_CLOSE -> fd_close_posix -> close
This is in preparation of removing the fd parameter
from the SMB_VFS_CLOSE function. But it is also the right
place for the pending close calls anyways.
Michael
|
|
|
|
| |
Michael
|
|
|
|
| |
Michael
|
|
|
|
| |
Michael
|
| |
|
|
|
|
|
|
| |
locking.c:open_read_only was unused
don't export the silly boolean flag locking_init(bool read_only)
|
| |
|
|
|
|
| |
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.
|
|
|
|
| |
Patch from Ofir Azoulay <Ofir.Azoulay@expand.com> -- thanks
|
| |
|
|
|
|
| |
Jeremy.
|
|
|
|
| |
failed expression in SMB_ASSERT.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This replaces the internal explicit dev/ino file id representation by a
"struct file_id". This is necessary as cluster file systems and NFS
don't necessarily assign the same device number to the shared file
system. With this structure in place we can now easily add different
schemes to map a file to a unique 64-bit device node.
Jeremy, you might note that I did not change the external interface of
smb_share_modes.c.
Volker
|
| |
|
|
|
|
|
|
| |
and fix all compiler warnings in the users
metze
|
|
|
|
|
|
|
|
| |
Move more error code returns to NTSTATUS.
Client test code to follow... See if this
passes the build-farm before I add it into
3.0.25.
Jeremy.
|
| |
|
| |
|
|
|
|
|
| |
Fix a small one first.... (easy to valgrind).
Jeremy
|
|
|
|
|
|
|
| |
We shouldn't allow this on the same smbd, but the cifsfs
client negotiates POSIX locks then sends Windows ones.
Doh ! Can't fix shipped client code....
Jeremy.
|
|
|
|
|
| |
look at the return code.
Jeremy.
|
|
|
|
|
|
| |
Hopefully will fix the build farm. Still a few errors
in RAW-LOCK to look at though...
Jeremy.
|
|
|
|
|
| |
cifsfs client code.
Jeremy.
|
|
|
|
|
|
|
| |
to do the upper layer directories but this is what
everyone is waiting for....
Jeremy.
|
|
|
|
|
| |
Klocwork #1129.
Jeremy.
|
|
|
|
|
|
|
|
| |
into 3.0. Also merge the new POSIX lock code - this
is not enabled unless -DDEVELOPER is defined.
This doesn't yet map onto underlying system POSIX
locks. Updates vfs to allow lock queries.
Jeremy.
|
|
|
|
|
| |
was confusing.
Jeremy.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
realloc can return NULL in one of two cases - (1) the realloc failed,
(2) realloc succeeded but the new size requested was zero, in which
case this is identical to a free() call.
The error paths dealing with these two cases should be different,
but mostly weren't. Secondly the standard idiom for dealing with
realloc when you know the new size is non-zero is the following :
tmp = realloc(p, size);
if (!tmp) {
SAFE_FREE(p);
return error;
} else {
p = tmp;
}
However, there were *many* *many* places in Samba where we were
using the old (broken) idiom of :
p = realloc(p, size)
if (!p) {
return error;
}
which will leak the memory pointed to by p on realloc fail.
This commit (hopefully) fixes all these cases by moving to
a standard idiom of :
p = SMB_REALLOC(p, size)
if (!p) {
return error;
}
Where if the realloc returns null due to the realloc failing
or size == 0 we *guarentee* that the storage pointed to by p
has been freed. This allows me to remove a lot of code that
was dealing with the standard (more verbose) method that required
a tmp pointer. This is almost always what you want. When a
realloc fails you never usually want the old memory, you
want to free it and get into your error processing asap.
For the 11 remaining cases where we really do need to keep the
old pointer I have invented the new macro SMB_REALLOC_KEEP_OLD_ON_ERROR,
which can be used as follows :
tmp = SMB_REALLOC_KEEP_OLD_ON_ERROR(p, size);
if (!tmp) {
SAFE_FREE(p);
return error;
} else {
p = tmp;
}
SMB_REALLOC_KEEP_OLD_ON_ERROR guarentees never to free the
pointer p, even on size == 0 or realloc fail. All this is
done by a hidden extra argument to Realloc(), BOOL free_old_on_error
which is set appropriately by the SMB_REALLOC and SMB_REALLOC_KEEP_OLD_ON_ERROR
macros (and their array counterparts).
It remains to be seen what this will do to our Coverity bug count :-).
Jeremy.
|
|
|
|
|
|
|
|
|
| |
tests on this as it's very late NY time (just wanted to get this work
into the tree). I'll test this over the weekend....
Jerry - in looking at the difference between the two trees there
seem to be some printing/ntprinting.c and registry changes we might
want to examine to try keep in sync.
Jeremy.
|
|
|
|
| |
Jeremy.
|
|
|
|
|
| |
to get back to me with a backtrace.
Jeremy.
|
|
|
|
| |
so our numbers don't get out of sync
|
| |
|
|
|
|
|
|
|
|
|
| |
allocation
functions so we can funnel through some well known functions. Should help greatly with
malloc checking.
HEAD patch to follow.
Jeremy.
|
|
|
|
|
|
| |
error return.
Jeremy.
|
|
|
|
| |
VFS_ macros at system side. We currently have one clash with AIX and its VFS_LOCK. Compiled and tested -- no new functionality or code, just plain rename of macros for yet-unreleased VFS API version. Needs to be done before a24 is out
|
|
|
|
|
|
|
|
|
| |
1. Finally work with cascaded modules with private data storage per module
2. Convert VFS API to macro calls to simplify cascading
3. Add quota support to VFS layer (prepare to NT quota support)
Patch by Stefan (metze) Metzemacher, with review of Jelmer and me
Tested in past few weeks. Documentation to new VFS API for third-party developers to follow
|
|
|
|
|
|
| |
<michael.steffens@hp.com>
Jeremy.
|
|
|
|
|
| |
named. Ensure we can query them.
Jeremy.
|
|
|
|
|
| |
Found via a post from Arcady Chernyak <Arcady.Chernyak@efi.com>.
Jeremy.
|
|
|
|
| |
Changed "SMB/Netbios" to "SMB/CIFS" in file header.
|
| |
|
| |
|
|
|
|
|
| |
Don. please check this out.
Jeremy.
|
|
|
|
|
| |
Treat this the same as an EFBIG error.
Jeremy
|