diff options
author | Michael Adam <obnox@samba.org> | 2008-03-20 14:24:12 +0100 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2008-03-20 15:01:52 +0100 |
commit | 13b894b01e404f1ed5f5c68b4e47d782f07dd7cc (patch) | |
tree | 0e0b067e3d30ce992fd81a9ac784dc0d2e1a01ed | |
parent | 2f01e055cf0a8d49f1d732f03c7d2bebd8e123ae (diff) | |
download | samba-13b894b01e404f1ed5f5c68b4e47d782f07dd7cc.tar.gz samba-13b894b01e404f1ed5f5c68b4e47d782f07dd7cc.tar.bz2 samba-13b894b01e404f1ed5f5c68b4e47d782f07dd7cc.zip |
registry: untangle assignment and if-statement in regdb_init().
Michael
(This used to be commit 504058df9706ee4e4c2e7fb1b1e41710bce2f87d)
-rw-r--r-- | source3/registry/reg_backend_db.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/registry/reg_backend_db.c b/source3/registry/reg_backend_db.c index 04b01797f7..a86edf0ff9 100644 --- a/source3/registry/reg_backend_db.c +++ b/source3/registry/reg_backend_db.c @@ -329,8 +329,8 @@ bool regdb_init( void ) return true; } - if ( !(regdb = db_open(NULL, state_path("registry.tdb"), 0, REG_TDB_FLAGS, O_RDWR, 0600)) ) - { + regdb = db_open(NULL, state_path("registry.tdb"), 0, REG_TDB_FLAGS, O_RDWR, 0600); + if (!regdb) { regdb = db_open(NULL, state_path("registry.tdb"), 0, REG_TDB_FLAGS, O_RDWR|O_CREAT, 0600); if ( !regdb ) { DEBUG(0,("regdb_init: Failed to open registry %s (%s)\n", |