diff options
author | Derrell Lipman <derrell@samba.org> | 2005-06-22 02:39:07 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:18:41 -0500 |
commit | fdc0450db25021eddcc65d032fd3fd8ca5976928 (patch) | |
tree | 936ca067bde179cb18c349f858ec371a65ae5502 /source4/lib/ldb/common | |
parent | 8a68f96f8cea2c53c8babf2ec826dfc6ef1cc199 (diff) | |
download | samba-fdc0450db25021eddcc65d032fd3fd8ca5976928.tar.gz samba-fdc0450db25021eddcc65d032fd3fd8ca5976928.tar.bz2 samba-fdc0450db25021eddcc65d032fd3fd8ca5976928.zip |
r7828: Although there is still plenty to do, ldb_sqlite3 now passes the set of tests
in tests/test-sqlite3.sh (tests/test-generic.sh).
There are lots of optimizations still TBD, and some things are REALLY slow
right now (e.g. each add() operation takes 1/3 - 1/2 second) but it's ready for
interested parties to poke it and prod it and see how (un)reasonable it is.
Play away.
Still to be implemented or improved:
- tdb specials (@MODULES, @SUBCLASSES, etc.)
- all DNs are case-folded in their entirty right now (since doing otherwise
would require @ATTRIBUTES to be implemented)
- speed improvements and optimizations. I am quite confident that the
excessively slow add() operation can be much improved, and other areas
can be somewhat improved.
(This used to be commit 1dd865005594671e7effe06fb088fa97fa08de0b)
Diffstat (limited to 'source4/lib/ldb/common')
-rw-r--r-- | source4/lib/ldb/common/ldb.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/source4/lib/ldb/common/ldb.c b/source4/lib/ldb/common/ldb.c index e268a8d0d7..63526dfe2e 100644 --- a/source4/lib/ldb/common/ldb.c +++ b/source4/lib/ldb/common/ldb.c @@ -76,7 +76,7 @@ int ldb_connect(struct ldb_context *ldb, const char *url, unsigned int flags, co #endif #if HAVE_SQLITE3 else if (strncmp(url, "sqlite:", 7) == 0) { - ldb_ctx = lsqlite3_connect(url, flags, options); + ret = lsqlite3_connect(ldb, url, flags, options); } #endif else { @@ -168,6 +168,22 @@ int ldb_rename(struct ldb_context *ldb, const char *olddn, const char *newdn) } /* + create a named lock +*/ +int ldb_lock(struct ldb_context *ldb, const char *lockname) +{ + return ldb->modules->ops->named_lock(ldb->modules, lockname); +} + +/* + release a named lock +*/ +int ldb_unlock(struct ldb_context *ldb, const char *lockname) +{ + return ldb->modules->ops->named_unlock(ldb->modules, lockname); +} + +/* return extended error information */ const char *ldb_errstring(struct ldb_context *ldb) |