summaryrefslogtreecommitdiff
path: root/source3/locking/locking.c
AgeCommit message (Collapse)AuthorFilesLines
2012-01-13Add comments to all functions (to help me understand it better).Jeremy Allison1-0/+5
Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Fri Jan 13 01:35:03 CET 2012 on sn-devel-104
2012-01-12s3: Move the share_mode_lock handling to its own fileVolker Lendecke1-415/+0
Signed-off-by: Jeremy Allison <jra@samba.org>
2012-01-12s3: Put an indirection layer into share_mode_lockVolker Lendecke1-133/+147
Signed-off-by: Jeremy Allison <jra@samba.org>
2012-01-12s3: Introduce get_share_mode_lock_fresh()Volker Lendecke1-11/+19
This slightly simplifies the code path for all callers which assume that a share mode exists already. Only the callers in open_file_ntcreate and open_directory will ever create new share modes. Signed-off-by: Jeremy Allison <jra@samba.org>
2012-01-12s3: Replace fill_share_mode_lock()Volker Lendecke1-84/+67
This replaces fill_share_mode_lock() with the two routines fresh_share_mode_lock() and parse_share_modes(). This lifts the decision whether a share mode already existed on level up. Signed-off-by: Jeremy Allison <jra@samba.org>
2012-01-06Fix format warning message.Jeremy Allison1-1/+1
2011-12-25s3: Fix a 64-bit warningVolker Lendecke1-1/+1
2011-12-16s3:locking: avoid using sconn_server_id()Stefan Metzmacher1-6/+6
metze
2011-12-15s3: Fix a typoVolker Lendecke1-1/+1
Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Thu Dec 15 23:35:28 CET 2011 on sn-devel-104
2011-12-14s3: Remove UNUSED_SHARE_MODE_ENTRYVolker Lendecke1-44/+19
2011-12-13s3: Move can_set_delete_on_close to smbd/Volker Lendecke1-59/+0
2011-12-13s3: Use talloc_tos() in set_write_time()Volker Lendecke1-1/+1
Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Tue Dec 13 15:44:58 CET 2011 on sn-devel-104
2011-12-13s3: Use talloc_tos() in set_sticky_write_time()Volker Lendecke1-1/+1
2011-12-02s3: Use autogenerated open_files.idlVolker Lendecke1-349/+65
2011-11-23s3: Fix a valgrind errorVolker Lendecke1-1/+1
Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Wed Nov 23 19:17:20 CET 2011 on sn-devel-104
2011-11-23s3: Replace delete_token_list by an arrayVolker Lendecke1-50/+66
This will make it easier to convert locking.tdb to IDL, and I don't think there will be enough entries to justify a linked list over an array. Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Wed Nov 23 09:02:12 CET 2011 on sn-devel-104
2011-10-27s3: Use serverids_exist in parse_share_modesVolker Lendecke1-1/+23
This is the main reason for the preceding commits. We need to reduce the number of round-trips to ctdb when checking the locking record entries for existence. Using the plural version of process_exists gets the number of round-trips to ctdb for process_exists down to 1.
2011-10-27s3: Use talloc_tos() in parse_share_modes()Volker Lendecke1-1/+1
2011-10-12Fix bug #8515 - Empty CIFS share can be blocked for other clients by ↵Volodymyr Khomenko1-0/+8
deleting it via empty path (DELETE_PENDING until the last client) Disallow "." in can_set_delete_on_close(). Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Wed Oct 12 21:07:27 CEST 2011 on sn-devel-104
2011-10-11s3:locking: convert locking.c to use dbwrap wrapper functions onlyMichael Adam1-12/+31
Avoid direct use of the db_record and db_context structs.
2011-07-29s3:dbwrap: move all .c and .h files of dbwrap to lib/dbwrap/Michael Adam1-1/+1
Autobuild-User: Michael Adam <obnox@samba.org> Autobuild-Date: Fri Jul 29 13:34:22 CEST 2011 on sn-devel-104
2011-07-29s3:dbwrap: move db_open() to a file dbwrap_open.c of its own.Michael Adam1-0/+1
Also start new folder lib/dbwrap/ where dbwrap_open.c is stored and make the fallbacke implementation functoins non-static and create a dbwrap_private.h header file that contains their prototypes.
2011-06-20tdb_compat: Higher level API fixes.Rusty Russell1-1/+1
My previous patches fixed up all direct TDB callers, but there are a few utility functions and the db_context functions which are still using the old -1 / 0 return codes. It's clearer to fix up all the callers of these too, so everywhere is consistent: non-zero means an error. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2011-06-09s3-talloc Change TALLOC_MEMDUP() to talloc_memdup()Andrew Bartlett1-1/+1
Using the standard macro makes it easier to move code into common, as TALLOC_MEMDUP isn't standard talloc.
2011-06-09s3-talloc Change TALLOC_ZERO_P() to talloc_zero()Andrew Bartlett1-3/+3
Using the standard macro makes it easier to move code into common, as TALLOC_ZERO_P isn't standard talloc.
2011-06-09s3-talloc Change TALLOC_P() to talloc()Andrew Bartlett1-3/+3
Using the standard macro makes it easier to move code into common, as TALLOC_P isn't standard talloc.
2011-06-09s3-talloc Change TALLOC_ARRAY() to talloc_array()Andrew Bartlett1-3/+3
Using the standard macro makes it easier to move code into common, as TALLOC_ARRAY isn't standard talloc.
2011-05-28s3: Fix a tiny memleak in copy_unix_tokenVolker Lendecke1-0/+1
Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Sat May 28 11:47:11 CEST 2011 on sn-devel-104
2011-05-28s3: Use talloc_memdup in copy_unix_tokenVolker Lendecke1-2/+2
2011-05-28s3: Fix some nonempty blank linesVolker Lendecke1-11/+11
2011-05-06s3: only include tdb headers where needed.Günther Deschner1-0/+1
Guenther
2011-05-04Fix the only place we reply on the NULL handling for the source in safe_strcpy.Jeremy Allison1-10/+18
2011-04-29s3-smb Use FILE_ATTRIBUTE_READONLY intead of aRONLYAndrew Bartlett1-1/+1
This means we use just one constant for this file attribute. Andrew Bartlett
2011-04-16Trying to track down the SMB2 error. Add an invariant test.Jeremy Allison1-1/+4
Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Sat Apr 16 02:15:38 CEST 2011 on sn-devel-104
2011-03-30s3-messages: make ndr_messaging.h part of messages.h.Günther Deschner1-1/+0
Guenther
2011-03-30s3-messages: only include messages.h where needed.Günther Deschner1-0/+1
Guenther
2011-03-30s3-locking: move locking prototypes out of proto.h.Günther Deschner1-0/+1
Will later become part of locking.h Guenther
2011-03-30s3-includes: only include system/filesys.h when needed.Günther Deschner1-0/+1
Guenther
2011-03-17Nulling out the op_mid is never the right thing to do. We depend onJeremy Allison1-1/+0
this value when searching for specific share mode entries. Jeremy. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Thu Mar 17 19:59:51 CET 2011 on sn-devel-104
2011-03-02s3-server_id: only include server_id where needed.Günther Deschner1-0/+1
Guenther
2011-03-01s3-auth struct security_unix_token replaces UNIX_USER_TOKENAndrew Bartlett1-11/+11
2011-01-26Missed one debug printf of name_hash. Ensure always use %x.Jeremy Allison1-2/+2
Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Wed Jan 26 00:46:28 CET 2011 on sn-devel-104
2011-01-25Fix bug #7863 - Unlink may unlink wrong file when hardlinks are involved.Jeremy Allison1-93/+239
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.
2011-01-25Add uint32_t name_hash argument (currently unused) to get_file_infos().Jeremy Allison1-0/+1
Will be used when we store more than one delete on close token.
2011-01-25Add name_hash into the share mode entry struct (as yet only use for renames ↵Jeremy Allison1-2/+15
to identify a specific path).
2010-10-12libcli/security Provide a common, top level libcli/security/security.hAndrew Bartlett1-0/+1
This will reduce the noise from merges of the rest of the libcli/security code, without this commit changing what code is actually used. This includes (along with other security headers) dom_sid.h and security_token.h Andrew Bartlett Autobuild-User: Andrew Bartlett <abartlet@samba.org> Autobuild-Date: Tue Oct 12 05:54:10 UTC 2010 on sn-devel-104
2010-09-27Change to using TDB_INCOMPATIBLE_HASH (the jenkins hash) on allJeremy Allison1-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.
2010-08-26s3-build: use dbwrap.h only where needed.Günther Deschner1-0/+1
Guenther
2010-08-07s3: Remove smbd_messaging_context() from send_stat_cache_delete_message()Volker Lendecke1-1/+2
2010-07-05s3: Remove procid_self() from fill_deferred_open_entry()Volker Lendecke1-6/+9