 -      memcpy(ret, elt, sizeof(CurFile));
 -      realfree(elt);
 -//    Dmsg1(dbglvl, "lookup <%s> ok\n", fname);
-+      db->close(db, DB_NOSYNC);
-+      db=NULL;
-+      free_pool_memory(hash_name);
-+      hash_name = NULL;
++      destroy();
 +      Jmsg(jcr, M_ERROR, 1, _("Can't setup hash disk ERR=%i\n"), ret);
 +      return false;
     }
 -   return found;
++   
++   first_pass=0;
 +
 +   return true;
  }

+   DBT dbkey;
+   DBT dbdata;
+   POOLMEM *hash_name;          /* file name for hash */
+};
+
+void AccurateBackendDB::destroy()

    return true;
 }
 
@@ -228,7 +346,8 @@
  */
 bool accurate_send_deleted_list(JCR *jcr)
 {
