From 6727429aea4505d085bcf6f22dd316e7123f0e83 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Wed, 9 Nov 2011 11:14:38 +0100 Subject: s3:registry: prevent unnecessary transactions in regdb_init Skip the transaction for the upgrade code, if the database is already at code-level. Autobuild-User: Michael Adam Autobuild-Date: Wed Nov 9 15:06:59 CET 2011 on sn-devel-104 --- source3/registry/reg_backend_db.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source3') diff --git a/source3/registry/reg_backend_db.c b/source3/registry/reg_backend_db.c index 7fa6249cec..4d4aaeb4b5 100644 --- a/source3/registry/reg_backend_db.c +++ b/source3/registry/reg_backend_db.c @@ -687,6 +687,10 @@ WERROR regdb_init(void) vers_id = REGDB_VERSION_V1; } + if (vers_id == REGDB_CODE_VERSION) { + return WERR_OK; + } + if (vers_id > REGDB_CODE_VERSION || vers_id == 0) { DEBUG(0, ("regdb_init: unknown registry version %d " "(code version = %d), refusing initialization\n", -- cgit