summaryrefslogtreecommitdiff
path: root/source3/smbd/reply.c
AgeCommit message (Collapse)AuthorFilesLines
2007-10-10r17220: If we're going to fail a write with an errno, makeJeremy Allison1-0/+4
sure we return -1. Jeremy. (This used to be commit 89b83237b03066785ca4bf3b9d120519bddeffad)
2007-10-10r17108: Make the default timeout parameter for lock waitingJeremy Allison1-3/+3
be lp_lock_spin(). lock spin count is no longer used. I'll update the man pages. Jeremy. (This used to be commit 0451a170c9be88399202abd225af35ddc45023f0)
2007-10-10r17107: Make the 200 ms timeout value tunable in local.h...Jeremy Allison1-3/+3
Might need to be a parameter ? Jeremy. (This used to be commit 98d8d9399bb287319578daaf2a2fb42f3c48f858)
2007-10-10r17106: Match Windows timing values on locks.Jeremy Allison1-0/+5
Jeremy. (This used to be commit b5aaff665937313370e0e87225e146f9af7b7e67)
2007-10-10r17105: Fix the race Volker found - we had a non-lockedJeremy Allison1-81/+53
region between detecting a pending lock was needed and when we added the blocking lock record. Make sure that we hold the lock over all this period. Removed the old code for doing blocking locks on SMB requests that never block (the old SMBlock and friends). Discovered something interesting about the strange NT_STATUS_FILE_LOCK_CONFLICT return. If we asked for a lock with zero timeout, and we got an error of NT_STATUS_FILE_LOCK_CONFLICT, treat it as though it was a blocking lock with a timeout of 150 - 300ms. This only happens when timeout is sent as zero and can be seen quite clearly in ethereal. This is the real replacement for old do_lock_spin() code. Re-worked the blocking lock select timeout to correctly use milliseconds instead of the old second level resolution (far too coarse for this work). Jeremy. (This used to be commit b81d6d1ae95a3d3e449dde629884b565eac289d9)
2007-10-10r17098: Samba3 now cleanly passes Samba4 RAW-LOCK tortureJeremy Allison1-47/+76
test. Phew - that was painful :-). But what it means is that we now implement lock cancels and I can add lock cancels into POSIX lock handling which will fix the fast/slow system call issue with cifsfs ! Jeremy. (This used to be commit f1a9cf075b87c76c032d19da0168424c90f6cb3c)
2007-10-10r16945: Sync trunk -> 3.0 for 3.0.24 code. Still needJeremy Allison1-80/+92
to do the upper layer directories but this is what everyone is waiting for.... Jeremy. (This used to be commit 9dafb7f48ca3e7af956b0a7d1720c2546fc4cfb8)
2007-10-10r16397: Fix Klocwork #11767 and drasticly simplify theJeremy Allison1-0/+7
logic in smbd/process.c. All interested (Volker, Jerry, James etc). PLEASE REVIEW THIS CHANGE. The logic should be identical but *much* easier to follow and change (and shouldn't confuse Klockwork :-). Jeremy. (This used to be commit d357f8b33594472ffa78d0a112accccc2a8b1fe7)
2007-10-10r15951: oplock_request must be an int, not a BOOL. WeJeremy Allison1-3/+3
were getting away with mixing types. Not cool. Jeremy. (This used to be commit ad3bc112a21afd3a04449ec3f604e017d753c224)
2007-10-10r15450: Change profiling data macros to use stack variables rather thanJames Peach1-7/+8
globals. This catches mismatched start/end calls and removes the need for special nested profiling calls. (This used to be commit ee750498812190edd3ec52ca3c750258f3b8a97a)
2007-10-10r15112: Move strict locking default to auto. Fix up the errorJeremy Allison1-1/+1
return for one of the Samba4 torture tests. Jeremy. (This used to be commit 9db6617756ff155eb7549c3c622a9920189e577d)
2007-10-10r15030: On a performace hunt... Remove as many extraneousJeremy Allison1-16/+16
memset's as possible. Jeremy. (This used to be commit 1217ed392b75aa8bfefa9c3f1ec5fa3bba841ee0)
2007-10-10r15020: Fix issue with samba4 netbench torture tester,Jeremy Allison1-1/+8
it sends break replies to "break to none from level2" requests and it shouldn't. Just don't log a debug level zero message. Jeremy. (This used to be commit dc6a13da33a031d0c2374b692737dbe9215f0f74)
2007-10-10r15018: Merge Volker's ipc/trans2/nttrans changes overJeremy Allison1-26/+86
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. (This used to be commit 08e52ead03304ff04229e1bfe544ff40e2564fc7)
2007-10-10r14574: Allow use of sendfile as long as the write cache has not been enabledJames Peach1-3/+4
on the particular file we are performing I/O on, irrespective of whether the write cache is globally enabled (This used to be commit 0809e2cb1dfff1cd0e8631b23b415cb2d8a67312)
2007-10-10r14460: SMBexit closes by pid and vuid. Tested with smbtorture.Jeremy Allison1-1/+1
Jeremy. (This used to be commit 71e81580421225d5b35a25d46a7b6064a826685c)
2007-10-10r13571: Replace all calls to talloc_free() with thye TALLOC_FREE()Gerald Carter1-5/+5
macro which sets the freed pointer to NULL. (This used to be commit b65be8874a2efe5a4b167448960a4fcf6bd995e2)
2007-10-10r13293: Rather a big patch I'm afraid, but this should fix bug #3347Jeremy Allison1-13/+13
by saving the UNIX token used to set a delete on close flag, and using it when doing the delete. libsmbsharemodes.so still needs updating to cope with this change. Samba4 torture tests to follow. Jeremy. (This used to be commit 23f16cbc2e8cde97c486831e26bcafd4ab4a9654)
2007-10-10r12956: Fix for bug #3035 from SATOH Fumiyasu <fumiyas@miraclelinux.com>Jeremy Allison1-1/+13
On a Windows share, a file with read-only dosmode can be opened with DELETE_ACCESS. But on a Samba share (delete readonly = no), it fails with NT_STATUS_CANNOT_DELETE error. This semantic causes a problem that a user can not rename a file with read-only dosmode on a Samba share from a Windows command prompt (i.e. cmd.exe, but can rename from Windows Explorer). Jeremy. (This used to be commit dd185c7aa8de156dab58b065bf73905b2a29f40d)
2007-10-10r12491: End profile fixes from SATOH Fumiyasu <fumiya@samba.gr.jp>.Jeremy Allison1-1/+1
Jeremy. (This used to be commit 2187502732e41690bf266f229312bb9c7177cf22)
2007-10-10r12234: Reduce the race condition for renames by holding the lockJeremy Allison1-19/+29
longer. Instigated by complaints on the fix for #3303 from SATOH Fumiyasu <fumiyas@miraclelinux.com>. Jeremy. (This used to be commit 855f5f8c32aa530dbad244805a40200824724618)
2007-10-10r12213: Final fix for #3303 - send rename messages to smbd'sJeremy Allison1-5/+23
that have open file handles to allow them to correctly implement delete on close. There is a further correctness fix I'm intending to add to this to cope with different share paths, but not right now... Jeremy. (This used to be commit 932e337db8788e75344e1c7cf1ef009d090cb039)
2007-10-10r12194: Ensure that when we set a connection path we've canonicalizedJeremy Allison1-1/+1
the name (must be abolute - start with /, must not end in /, must have ./ and ../ removed). Of course for realpath resolved paths this won't be the case but for others we need this name to be canonicalized. This name is going into the sharemode db for #3303 so needs to be in a normalized format. Jeremy. (This used to be commit 22e3300911809692b595f49e87d91e3111923e6a)
2007-10-10r11511: A classic "friday night check-in" :-). This moves muchJeremy Allison1-18/+20
of the Samba4 timezone handling code back into Samba3. Gets rid of "kludge-gmt" and removes the effectiveness of the parameter "time offset" (I can add this back in very easily if needed) - it's no longer being looked at. I'm hoping this will fix the problems people have been having with DST transitions. I'll start comprehensive testing tomorrow, but for now all modifications are done. Splits time get/set functions into srv_XXX and cli_XXX as they need to look at different timezone offsets. Get rid of much of the "efficiency" cruft that was added to Samba back in the day when the C library timezone handling functions were slow. Jeremy. (This used to be commit 414303bc0272f207046b471a0364fa296b67c1f8)
2007-10-10r11451: Fix -O1 "might be using uninitialized" errors.Jeremy Allison1-1/+1
Jeremy. (This used to be commit cab76c3c33883aad444eefb6562ab1b27d9ca88a)
2007-10-10r11448: Move decl before code.Jeremy Allison1-1/+2
Jeremy. (This used to be commit f22822790cdbbe7d5a237421c1eda73a504e488d)
2007-10-10r11428: Fix bug #3192 by actually hooking up the dfree cachingJeremy Allison1-1/+1
function. Oops. Jeremy. (This used to be commit 7edb26e7657fc01710abe563b941779749409ef2)
2007-10-10r11420: Fix issue pointed out by Dina Fine <dina@exanet.com>. We canJeremy Allison1-44/+78
only tell at parse time from the wire if an incoming name has wildcards or not. If it's a mangled name and we demangle the demangled name may contain wildcard characters. Ensure these are ignored. Jeremy. (This used to be commit 4cd8e2a96b98ff711905e8c6f416b22440c16062)
2007-10-10r11137: Compile with only 2 warnings (I'm still working on that code) on a gcc4Jeremy Allison1-2/+2
x86_64 box. Jeremy. (This used to be commit d720867a788c735e56d53d63265255830ec21208)
2007-10-10r10750: Ensure we match W2K3 in forcing DOS errors in a couple of cases.Jeremy Allison1-2/+2
Jeremy. (This used to be commit 62ba3454251daf59071a6b2663035b04c5438647)
2007-10-10r10749: Remove one more Samba4 smbtorture RAW-OPEN difference from W2K3.Jeremy Allison1-1/+1
Jeremy. (This used to be commit 0e8cf8eef59e38ba9a79f6c688abe9f1ac3bf64d)
2007-10-10r10656: BIG merge from trunk. Features not copied overGerald Carter1-56/+77
* \PIPE\unixinfo * winbindd's {group,alias}membership new functions * winbindd's lookupsids() functionality * swat (trunk changes to be reverted as per discussion with Deryck) (This used to be commit 939c3cb5d78e3a2236209b296aa8aba8bdce32d3)
2007-10-10r10551: We need to check if the source path is a parent directory of the ↵Jeremy Allison1-0/+41
destination (ie. a rename of /foo/bar/baz -> /foo/bar/baz/bibble/bobble. If so we must refuse the rename with a sharing violation. Under UNIX the above call can *succeed* if /foo/bar/baz is a symlink to another area in the share. We probably need to check that the client is a Windows one before disallowing this as a UNIX client (one with UNIX extensions) can know the source is a symlink and make this decision intelligently. Found by an excellent bug report from <AndyLiebman@aol.com>. Jeremy. (This used to be commit fc311adc7964feef5bac85096727f54922d1186c)
2007-10-10r10136: Fix for bug #3060 from Leo Weppelman <leo@wau.mis.ah.nl>.Jeremy Allison1-1/+1
Ensure SMBcreate truncates the file if it exists. Jeremy. (This used to be commit 9014b0ddcbd87c98613f06033718e4091e3be21c)
2007-10-10r9985: Move the all the strict sync logic into file_sync().James Peach1-13/+7
(This used to be commit cc680bbe22b8bfc5a1900f11c2cbaeca3a9f9922)
2007-10-10r8609: Fix for bugid #2889. I think the problem is that the top 16 bits of ↵Jeremy Allison1-1/+3
the "server state" field must be non-zero. As we're using the 32 bit field as an offset then normally this field will be zero. W2K3 fills this field with a counter enumerating the number of SMBsearch calls on this directory - starting at 1. Add back the 1<<31 bit flag DPTR_MASK to ensure this is non-zero - with better checks on use. Jeremy. (This used to be commit 6415657942c49ea51d4e4f4ee2189c7d70b9c5fa)
2007-10-10r8556: Fix bug #2878 - Norton commander not running on OS/2 client - we wereJeremy Allison1-1/+1
not correctly returning the requested open mode. Thanks to alex@infobit.ru for reporting this. Jeremy. (This used to be commit 7ff7211b808e708c00a3b0f57be8d1af3c632bd7)
2007-10-10r8457: Fix from Marcel Müller <mueller@maazl.de> to ensureJeremy Allison1-1/+1
we correctly set the return packet size to include the pad bytes in reply_readbmpx(). Jeremy. (This used to be commit 3070ec288c64880485ed159d512e91346f5d1b4e)
2007-10-10r8290: Fix for bug in SMBwriteBraw where we incorrectlyJeremy Allison1-1/+2
returned the number of bytes written. Patch from Marcel Müller <mueller@maazl.de>. Jeremy. (This used to be commit 81e7a4a2cfd2d4764d757702f17635e5007e59de)
2007-10-10r8219: Merge the new open code from HEAD to 3.0. Haven't yet run the tortureJeremy Allison1-138/+260
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. (This used to be commit c7fe18761e2c753afbffd3a78abff46472a9b8eb)
2007-10-10r7963: Add aio support to 3.0.Jeremy Allison1-7/+0
Jeremy. (This used to be commit 1de27da47051af08790317f5b48b02719d6b9934)
2007-10-10r7893: Add in the extra parameters to opendir() to fix the large ↵Jeremy Allison1-28/+24
directory/insane app problem. Rev vfs version. Doesn't change the normal codepath. Jeremy. (This used to be commit 0f03a6bdcdbdf60da81e0aeffa84ac6e48fc6a04)
2007-10-10r7842: With the patch I sent Steve yesterday this gives us complete POSIX ↵Jeremy Allison1-1/+11
pathnames. ie. files containing : and \ can be accessed from Linux. Jeremy. (This used to be commit e9b8d23d6138d909a65ea70b2e801881e8333b38)
2007-10-10r7620: when adding a new printer driver, we should copy the filesGerald Carter1-1/+1
(not move) to the W32X86/{2,3}/ directory. Printmig.exe copies the driver files for all drivers to print$/W32X86 and the calls AddPrinterDriver() for each driver. If we move the file, then adding a driver which shares a file with a previous driver will fail. I can now restore drivers in bulk to a Samba 3 server. (This used to be commit 46cd95c9b48a00a51139d3654352d4399b774a9b)
2007-10-10r7618: Typo...Jeremy Allison1-1/+1
Jeremy. (This used to be commit 65d1365700588949fc5576c7dd525fc530a15ff4)
2007-10-10r7617: Fix for bug #2801 - delete veto files was broken with the newJeremy Allison1-2/+2
large directory code. Jeremy. (This used to be commit f397cc08b5628913af4d7f9c2c6d20c778e5d8ca)
2007-10-10r7447: Sync up a little between HEAD and 3.0 in preparation for movingJeremy Allison1-5/+30
the AIO code across. Jeremy. (This used to be commit e9604e65f4337a4163398f1f2c71e13da7993ed4)
2007-10-10r6977: Fix bug #2735 (not mangling control characters) plusJeremy Allison1-0/+6
ensure we don't create files with control characters either. Jeremy. (This used to be commit 0ca2423c706423a07721e375345b6d45a45cbcf4)
2007-10-10r6673: Fix the write cache based on some VERY good detective workJeremy Allison1-10/+7
from Ingo Kilian <ikilian@web.de>. You must do a make clean after updating this. Jeremy. (This used to be commit 3b2cd19fcb8ce38578b122fd6ae722b73081dcda)
2007-10-10r6633: Added "check_path_syntax_posix()" in preparation for handlingJeremy Allison1-1/+95
POSIX pathnames. Not yet used. Jeremy. (This used to be commit 381da9b55d6a3fda2ba4a3f12bee50853b7fd3b3)