]> git.sur5r.net Git - openldap/commitdiff
Cleanup prev commit
authorHoward Chu <hyc@openldap.org>
Wed, 18 Feb 2009 00:17:59 +0000 (00:17 +0000)
committerHoward Chu <hyc@openldap.org>
Wed, 18 Feb 2009 00:17:59 +0000 (00:17 +0000)
servers/slapd/back-bdb/init.c

index f34271a0dba71790531fe521d6a899894ae7f808..a029fee3c8266d843572705cc1de94c5944a3a1a 100644 (file)
@@ -336,15 +336,13 @@ shm_retry:
                if ( !do_recover && bdb->bi_shm_key ) {
                        bdb->bi_dbenv->close( bdb->bi_dbenv, 0 );
                        rc = db_env_create( &bdb->bi_dbenv, 0 );
-                       if( rc == 0 ) {
+                       if( rc == 0 && do_retry ) {
                                Debug( LDAP_DEBUG_ANY, LDAP_XSTRING(bdb_db_open)
                                        ": database \"%s\": "
                                        "shared memory env open failed, assuming stale env.\n",
                                        be->be_suffix[0].bv_val, 0, 0 );
-                               if ( do_retry ) {
-                                       do_retry = 0;
-                                       goto shm_retry;
-                               }
+                               do_retry = 0;
+                               goto shm_retry;
                        }
                }
                Debug( LDAP_DEBUG_ANY,