r1011: fix bad merge (from a few months ago) and ensure that we always use tdb_open_l...
authorGerald Carter <jerry@samba.org>
Fri, 4 Jun 2004 17:26:09 +0000 (17:26 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 15:51:53 +0000 (10:51 -0500)
source/locking/brlock.c
source/locking/locking.c
source/printing/printing_db.c
source/smbd/connection.c
source/smbd/session.c

index 47001c8b89cdfacd0f3d66102052c7efbb814f8f..990a6a25d2fba201bc09e296662bb9c6cfbcbe4e 100644 (file)
@@ -246,8 +246,8 @@ void brl_init(int read_only)
 {
        if (tdb)
                return;
-       tdb = tdb_open_ex(lock_path("brlock.tdb"), 0,  TDB_DEFAULT|(read_only?0x0:TDB_CLEAR_IF_FIRST),
-                      read_only?O_RDONLY:(O_RDWR|O_CREAT), 0644, smbd_tdb_log);
+       tdb = tdb_open_log(lock_path("brlock.tdb"), 0,  TDB_DEFAULT|(read_only?0x0:TDB_CLEAR_IF_FIRST),
+                      read_only?O_RDONLY:(O_RDWR|O_CREAT), 0644 );
        if (!tdb) {
                DEBUG(0,("Failed to open byte range locking database\n"));
                return;
index 2a27d7d4cdc1c8b0c28cd874a426ae0168eb79cd..fd03a25940f8da8ef3472b84167348cad698745e 100644 (file)
@@ -283,10 +283,10 @@ BOOL locking_init(int read_only)
        if (tdb)
                return True;
 
-       tdb = tdb_open_ex(lock_path("locking.tdb"), 
+       tdb = tdb_open_log(lock_path("locking.tdb"), 
                       0, TDB_DEFAULT|(read_only?0x0:TDB_CLEAR_IF_FIRST), 
                       read_only?O_RDONLY:O_RDWR|O_CREAT,
-                      0644, smbd_tdb_log);
+                      0644);
 
        if (!tdb) {
                DEBUG(0,("ERROR: Failed to initialise locking database\n"));
index d402aa366f4e3f7a0dacc0887b7b730a2f9eb3d4..9efb3e8eadfc8c0921630aecb112285eed34ec3e 100644 (file)
@@ -96,8 +96,8 @@ struct tdb_print_db *get_print_db_byname(const char *printername)
                done_become_root = True;
        }
 
-       p->tdb = tdb_open_ex(printdb_path, 5000, TDB_DEFAULT, O_RDWR|O_CREAT, 
-               0600, smbd_tdb_log);
+       p->tdb = tdb_open_log(printdb_path, 5000, TDB_DEFAULT, O_RDWR|O_CREAT, 
+               0600);
 
        if (done_become_root)
                unbecome_root();
index a9ab14246150f95d2df848dbe947e58cc685cf5a..5bb76eb3bd83a6cf43093dcb2b015e26f3acc1d5 100644 (file)
@@ -29,8 +29,8 @@ static TDB_CONTEXT *tdb;
 TDB_CONTEXT *conn_tdb_ctx(void)
 {
        if (!tdb)
-               tdb = tdb_open_ex(lock_path("connections.tdb"), 0, TDB_CLEAR_IF_FIRST|TDB_DEFAULT, 
-                              O_RDWR | O_CREAT, 0644, smbd_tdb_log);
+               tdb = tdb_open_log(lock_path("connections.tdb"), 0, TDB_CLEAR_IF_FIRST|TDB_DEFAULT, 
+                              O_RDWR | O_CREAT, 0644);
 
        return tdb;
 }
@@ -131,8 +131,8 @@ BOOL claim_connection(connection_struct *conn, const char *name,int max_connecti
        TDB_DATA kbuf, dbuf;
 
        if (!tdb)
-               tdb = tdb_open_ex(lock_path("connections.tdb"), 0, TDB_CLEAR_IF_FIRST|TDB_DEFAULT, 
-                              O_RDWR | O_CREAT, 0644, smbd_tdb_log);
+               tdb = tdb_open_log(lock_path("connections.tdb"), 0, TDB_CLEAR_IF_FIRST|TDB_DEFAULT, 
+                              O_RDWR | O_CREAT, 0644);
 
        if (!tdb)
                return False;
index 61118f13dd9b2018f3c666cc851aade88ea7745c..91ebaeb830bcf187fb205ce9c5e9cf7a749bedbb 100644 (file)
@@ -34,8 +34,8 @@ BOOL session_init(void)
        if (tdb)
                return True;
 
-       tdb = tdb_open_ex(lock_path("sessionid.tdb"), 0, TDB_CLEAR_IF_FIRST|TDB_DEFAULT, 
-                      O_RDWR | O_CREAT, 0644, smbd_tdb_log);
+       tdb = tdb_open_log(lock_path("sessionid.tdb"), 0, TDB_CLEAR_IF_FIRST|TDB_DEFAULT, 
+                      O_RDWR | O_CREAT, 0644);
        if (!tdb) {
                DEBUG(1,("session_init: failed to open sessionid tdb\n"));
                return False;