summaryrefslogtreecommitdiff
path: root/source4/lib
diff options
context:
space:
mode:
authorMatthieu Patou <mat@matws.net>2010-01-12 02:23:13 +0300
committerAndrew Bartlett <abartlet@samba.org>2010-01-21 07:11:18 +1300
commit0cdc39e7302adf86010d23ef0f08f3cbdcf6b1b2 (patch)
tree58a438d6a472485468cb78bb44cc80d300c57603 /source4/lib
parenta4b01dd59c386c84776367b46b0fa726918dbebc (diff)
downloadsamba-0cdc39e7302adf86010d23ef0f08f3cbdcf6b1b2.tar.gz
samba-0cdc39e7302adf86010d23ef0f08f3cbdcf6b1b2.tar.bz2
samba-0cdc39e7302adf86010d23ef0f08f3cbdcf6b1b2.zip
Add a comment to tdb_wrap to explain why it should be used instead of directly using tdb
Diffstat (limited to 'source4/lib')
-rw-r--r--source4/lib/tdb_wrap.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/source4/lib/tdb_wrap.h b/source4/lib/tdb_wrap.h
index eb0191fb31..20ab53fb35 100644
--- a/source4/lib/tdb_wrap.h
+++ b/source4/lib/tdb_wrap.h
@@ -19,6 +19,13 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+/* IMPORTANT: tdb_wrap should be always prefered over tdb_context for end consumer functions
+ it's because if the code will be running inside smbd, then we must use the linked list
+ of open tdb files, to determine if the tdb we desire is already open
+ as otherwise, when you close the tdb (even on a different file descriptor),
+ ALL LOCKS are lost (due to a real screwup in the POSIX specification that nobody has been able to get fixed)
+*/
+
#ifndef _TDB_WRAP_H_
#define _TDB_WRAP_H_