From d5ed57608438eb4a95447b1680679af43e518ae1 Mon Sep 17 00:00:00 2001 From: Eric Bollengier Date: Wed, 9 Jul 2008 21:02:53 +0000 Subject: [PATCH] ebl Fix segfault during init git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@7352 91ce42f0-d328-0410-95d8-f526ca767f89 --- bacula/patches/testing/accurate-db.patch | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/bacula/patches/testing/accurate-db.patch b/bacula/patches/testing/accurate-db.patch index 03c712d0ba..3808bcfc5d 100644 --- a/bacula/patches/testing/accurate-db.patch +++ b/bacula/patches/testing/accurate-db.patch @@ -1,7 +1,7 @@ Index: src/filed/accurate.c =================================================================== ---- src/filed/accurate.c (revision 7346) -+++ src/filed/accurate.c (working copy) +--- src/filed/accurate.c (révision 7351) ++++ src/filed/accurate.c (copie de travail) @@ -32,193 +32,310 @@ #include "bacula.h" @@ -110,15 +110,15 @@ Index: src/filed/accurate.c + dbenv->set_errfile(dbenv, stderr); + dbenv->set_errpfx(dbenv, "hash"); + -+ -+ if ((ret = dbenv->open(dbenv, working_directory, DB_PRIVATE, 0)) != 0) { ++ int flags = DB_PRIVATE | DB_INIT_LOCK | DB_INIT_MPOOL | DB_CREATE | DB_THREAD; ++ if ((ret = dbenv->open(dbenv, working_directory, flags, 0)) != 0) { + Jmsg(jcr, M_ERROR, 1, _("Can't open initialize hash disk ERR=%i\n"), ret); + dbenv->close(dbenv, 0); + dbenv = NULL; + return false; + } + -+ dbenv->set_flags(dbenv, DB_TXN_NOSYNC | DB_TXN_WRITE_NOSYNC, 1); ++ dbenv->set_flags(dbenv, DB_TXN_NOSYNC, 1); + + if ((ret = db_create(&db, dbenv, 0)) != 0) { + Jmsg(jcr, M_ERROR, 1, _("Can't open accurate hash disk ERR=%i\n"), ret); @@ -574,8 +574,8 @@ Index: src/filed/accurate.c -#endif Index: src/filed/filed.h =================================================================== ---- src/filed/filed.h (revision 7346) -+++ src/filed/filed.h (working copy) +--- src/filed/filed.h (révision 7351) ++++ src/filed/filed.h (copie de travail) @@ -35,11 +35,35 @@ @@ -619,8 +619,8 @@ Index: src/filed/filed.h #include "findlib/find.h" Index: src/baconfig.h =================================================================== ---- src/baconfig.h (revision 7346) -+++ src/baconfig.h (working copy) +--- src/baconfig.h (révision 7351) ++++ src/baconfig.h (copie de travail) @@ -113,6 +113,12 @@ #endif /* HAVE_WIN32 */ @@ -636,8 +636,8 @@ Index: src/baconfig.h #include Index: src/jcr.h =================================================================== ---- src/jcr.h (revision 7346) -+++ src/jcr.h (working copy) +--- src/jcr.h (révision 7351) ++++ src/jcr.h (copie de travail) @@ -341,12 +341,7 @@ CRYPTO_CTX crypto; /* Crypto ctx */ DIRRES* director; /* Director resource */ -- 2.39.5