summaryrefslogtreecommitdiffstats
path: root/source3/libsmb/smb_share_modes.c
Commit message (Collapse)AuthorAgeFilesLines
* s3: Use autogenerated open_files.idlVolker Lendecke2011-12-021-0/+30
|
* replace: Add don't include unistd.h directly and add uid_wrapper.Andreas Schneider2011-10-271-0/+1
|
* tdb_compat: use tdb_open_compat.Rusty Russell2011-06-201-4/+6
| | | | | | | | | This is a helper for the common case of opening a tdb with a logging function, but it doesn't do all the work, since TDB1 and TDB2's log functions are different types. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* tdb_chainunlock: ignore return value.Rusty Russell2011-06-201-2/+3
| | | | | | | | | TDB2 returns void here. tdb_chainunlock will *always* return with the chain unlocked, but it will complain via the log function if it wasn't locked. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* tdb_chainlock: check returns for 0, not -1.Rusty Russell2011-06-201-1/+1
| | | | | | | | TDB2 returns a negative error number on failure. This is compatible if we always check for != 0 instead of == -1. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* tdb_store: check returns for 0, not -1.Rusty Russell2011-06-201-4/+4
| | | | | | | | TDB2 returns a negative error number on failure. This is compatible if we always check for != 0 instead of == -1. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* tdb_delete: check returns for 0, not -1.Rusty Russell2011-06-201-2/+2
| | | | | | | | TDB2 returns a negative error number on failure. This is compatible if we always check for != 0 instead of == -1. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* tdb_fetch_compat: use instead of tdb_fetch.Rusty Russell2011-06-201-5/+5
| | | | | | | This is a noop for tdb1. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* tdb_compat.h: divert every tdb build and includes to tdb_compatRusty Russell2011-06-201-1/+1
| | | | | | | | We change all the headers and wscript files to use tdb_compat; this means we have one place to decide whether to use TDB1 or TDB2. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* smb_share_modes: don't use tdb_jenkins_hash.Rusty Russell2011-06-201-4/+2
| | | | | | | | It's a nice hash, but this usage has nothing to do with TDB. So use the Jenkins hash directly from CCAN instead (it's the same one). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* s3: only include tdb headers where needed.Günther Deschner2011-05-061-0/+1
| | | | Guenther
* s3-includes: only include system/filesys.h when needed.Günther Deschner2011-03-301-0/+1
| | | | Guenther
* s3: Fix a C++ warningVolker Lendecke2011-02-141-1/+1
| | | | | Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Mon Feb 14 21:44:55 CET 2011 on sn-devel-104
* Don't use asprintf in this library - breaks the build on many systems. Fake ↵Jeremy Allison2011-02-091-3/+8
| | | | with malloc/memcpy.
* s3: Remove an unneeded checkVolker Lendecke2011-01-291-1/+1
| | | | | | | | In many other places we already assume that if asprintf returns !=-1 then the result is allocated. Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Sat Jan 29 15:00:09 CET 2011 on sn-devel-104
* From Metze - make sure we're using the same string length for the hash.Jeremy Allison2011-01-261-1/+1
| | | | | Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Wed Jan 26 18:32:15 CET 2011 on sn-devel-104
* Fix bug #7863 - Unlink may unlink wrong file when hardlinks are involved.Jeremy Allison2011-01-251-5/+4
| | | | | | Do this by keeping a linked list of delete on close tokens, one for each filename that identifies a path to the dev/inode. Use the jenkins hash of the pathname to identify the correct token.
* Add name_hash into the share mode entry struct (as yet only use for renames ↵Jeremy Allison2011-01-251-4/+32
| | | | to identify a specific path).
* Change to using TDB_INCOMPATIBLE_HASH (the jenkins hash) on allJeremy Allison2010-09-271-1/+1
| | | | | | | | | | TDB_CLEAR_IF_FIRST tdb's. For tdb's like gencache where we open without CLEAR_IF_FIRST and then with CLEAR_IF_FIRST if corrupt this is still safe to use as if opening an existing tdb the new hash will be ignored - it's only used on creating a new tdb not opening an old one. Jeremy.
* s3: Add extid to the dev/inode pairTim Prouty2009-02-191-12/+27
| | | | | | | | | | | This extends the file_id struct to add an additional generic uint64_t field: extid. For backwards compatibility with dev/inodes stored in xattr_tdbs and acl_tdbs, the ext id is ignored for these databases. This patch should cause no functional change on systems that don't use SMB_VFS_FILE_ID_CREATE to set the extid. Existing code that uses the smb_share_mode library will need to be updated to be compatibile with the new extid.
* Remove a global variableVolker Lendecke2009-01-011-13/+20
|
* fix some nonempty blank linesVolker Lendecke2009-01-011-5/+5
|
* RIP BOOL. Convert BOOL -> bool. I found a few interestingJeremy Allison2007-10-181-1/+1
| | | | | | | | bugs in various places whilst doing this (places that assumed BOOL == int). I also need to fix the Samba4 pidl generation (next checkin). Jeremy. (This used to be commit f35a266b3cbb3e5fa6a86be60f34fe340a3ca71f)
* r23798: updated old Temple Place FSF addresses to new URLAndrew Tridgell2007-10-101-2/+1
| | | | (This used to be commit c676a971142d7176fd5dbf21405fca14515a0a76)
* r23790: LGPLv3+ conversion for our LGPLv2+ library codeAndrew Tridgell2007-10-101-1/+1
| | | | (This used to be commit 1b78cace504f60c0f525765fbf59d9cc6506cd4d)
* r23183: Check in a change made by Tridge:Volker Lendecke2007-10-101-6/+6
| | | | | | | | | | | | | | 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 (This used to be commit 9b10dbbd5de8813fc15ebbb6be9b18010ffe8139)
* r22736: Start to merge the low-hanging fruit from the now 7000-line cluster ↵Volker Lendecke2007-10-101-5/+5
| | | | | | | | | | patch. This changes "struct process_id" to "struct server_id", keeping both is just too much hassle. No functional change (I hope ;-)) Volker (This used to be commit 0ad4b1226c9d91b72136310d3bbb640d2c5d67b8)
* r22154: Make struct smbdb_ctx an opaque pointer so users of the APIJeremy Allison2007-10-101-0/+5
| | | | | | don't need to have tdb.h. Jeremy. (This used to be commit 512542c90a78006bda3470eed7fb6d3f6e708eed)
* r22012: Ensure we use the same technique to pull the share modeJeremy Allison2007-10-101-19/+21
| | | | | | data out that locking/locking.c does. Jeremy. (This used to be commit 1fec4da6d6267289bf93f930de4cb5e21c450e15)
* r22009: change TDB_DATA from char * to unsigned char *Stefan Metzmacher2007-10-101-7/+7
| | | | | | | and fix all compiler warnings in the users metze (This used to be commit 3a28443079c141a6ce8182c65b56ca210e34f37f)
* r21191: Add in the POSIX open/mkdir/unlink calls.Jeremy Allison2007-10-101-0/+1
| | | | | | | | | 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. (This used to be commit 83dbbdff345fa9e427c9579183f4380004bf3dd7)
* r20883: W00t! I now understand how "delete on close" reallyJeremy Allison2007-10-101-1/+0
| | | | | | | | | | | | | | | | | works - even with the strange "initial delete on close" semantics. The "initial delete on close" flag isn't committed to the share mode db until the handle is closed, and is discarded if any real "delete on close" was set. This allows me to remove the "initial_delete_on_close" flag from the share db, and move it into a BOOL in files_struct. Warning ! You must do a make clean after this. Cope with the wrinkle in directory delete on close which is done differently from files. We now pass all Samba4 smbtortute BASE-DELETE tests except for the one checking that files can't be created in a directory which has the delete on close set (possibly expensive to fix). Jeremy. (This used to be commit f2df77a1497958c1ea791f1d2f4446b5fc3389b3)
* r20269: merge -r20264:20267 from SAMBA_3_0_24Herb Lewis2007-10-101-0/+4
| | | | | more no previous prototype warnings (This used to be commit 41be182f78762372ae13759ede5d2bd40a71d7f5)
* r17363: Some C++ warningsVolker Lendecke2007-10-101-5/+8
| | | | (This used to be commit fd82f185a2e0f94bfb75f4eee072556ad94bf27d)
* r16435: Add in the uid info that Jerry needs into theJeremy Allison2007-10-101-0/+1
| | | | | | | | share_mode struct. Allows us to know the unix uid of the opener of the file/directory. Needed for info level queries on open files. Jeremy. (This used to be commit d929323d6f513902381369d77bcd7b714346d713)
* r13331: No I didn't have to change the interface version...Jeremy Allison2007-10-101-22/+0
| | | | | Jeremy. (This used to be commit 2aed5b36409e05ac25b4492669f47d50be988f2c)
* r13329: Fix libsmbsharemodes.so to work with the stored delete token.Jeremy Allison2007-10-101-15/+23
| | | | | | | Less trouble than I thought plus it didn't need an interface change (thank goodness !). Jeremy. (This used to be commit dbe2572d1c713f46b0d1d0c405f88456c9336297)
* r13274: Fix for bug #3467. Not a show stopper.Jeremy Allison2007-10-101-0/+2
| | | | | | | jason qian <jason@infrant.com> was a *fantastic* help in tracking this down. Jeremy. (This used to be commit 9f4a9c70fa232047868e5d8a3f132a2dd6bfee82)
* r12203: Add the share path into the sharemode db. This involvesJeremy Allison2007-10-101-4/+33
| | | | | | | | | | | revving the minor version number for libsmbsharemodes (we now have a new _ex interface that takes the share path as well as the filename). Needed for #3303. Some code written by SATOH Fumiyasu <fumiya@samba.gr.jp> included in the changes to locking/locking.c. The smbstatus output is a bit of a mess and needs overhauling... Jeremy. (This used to be commit 9d93af713f8520ca506730dd32aa2b994937eaba)
* r11379: Remove external dependencies from sharemodes library.Jeremy Allison2007-10-101-4/+20
| | | | | Jeremy. (This used to be commit 7fb05872612c9e1816ac24d25a020073e3b41950)
* r10656: BIG merge from trunk. Features not copied overGerald Carter2007-10-101-41/+52
| | | | | | | | * \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)
* r10217: Remember to exit correctly when we find a matching entry to change.Jeremy Allison2007-10-101-1/+2
| | | | | Jeremy. (This used to be commit 142c84eb31a4f2577d5f4bb0f541440d84eb607f)
* r10215: Fix several memory corruption bugs now we're testing this.Jeremy Allison2007-10-101-33/+37
| | | | | Jeremy. (This used to be commit 3d1207aaf66bafd84935b21dbe1a0fd8efeb661d)
* r10204: I love valgrind :-). Found stupid missing parantheses :-).Jeremy Allison2007-10-101-1/+1
| | | | | Jeremy. (This used to be commit b406a202128c1ba9800784ab8c571584b37c746b)
* r10150: Fix from Steve Williams <steve@celineandsteve.com> to make the argsJeremy Allison2007-10-101-2/+2
| | | | | | consistent (uint64_t). Jeremy. (This used to be commit 08de7261720f7bfd72396ea7c9777dc0734c4593)
* r10135: Remove external dependencies for libsmbsharemodes.soJeremy Allison2007-10-101-10/+11
| | | | | Jeremy. (This used to be commit 2521ae826f1a0344c882090832646d56f248488f)
* r10054: Actually use the given db path (:-)Jeremy Allison2007-10-101-1/+5
| | | | | Jeremy. (This used to be commit ac7cf320dfa2fd980188e72c9b8baa726c5cdaa1)
* r10042: Add in external LGPL library for accessing the share mode db. AllowJeremy Allison2007-10-101-0/+452
others to examine & test. May not end up here eventually... Jeremy. (This used to be commit 7cc70ae63399eacd55bd0bf51ac2c7b004d761bf)