diff options
author | falkTX <falktx@falktx.com> | 2021-04-12 18:40:41 +0100 |
---|---|---|
committer | falkTX <falktx@falktx.com> | 2021-04-12 18:40:41 +0100 |
commit | d8b06051bfd4755d89fe29e0aeceb96c10c98e85 (patch) | |
tree | ef3cedf43ff479376ed7d62c95d8df80d4a51273 | |
parent | 1bba849fee76350a5289ac95eac123795a40cab9 (diff) | |
download | jack2-d8b06051bfd4755d89fe29e0aeceb96c10c98e85.tar.gz |
Log error message when cleaning previous DB, allow it on macOS too
-rw-r--r-- | common/JackMetadata.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/common/JackMetadata.cpp b/common/JackMetadata.cpp index 8cf00f32..ad2bdc93 100644 --- a/common/JackMetadata.cpp +++ b/common/JackMetadata.cpp @@ -123,9 +123,11 @@ int JackMetadata::PropertyInit() #endif if ((ret = fDBenv->open (fDBenv, dbpath, DB_CREATE | DB_INIT_LOCK | DB_INIT_MPOOL | DB_THREAD, 0)) != 0) { -#ifdef WIN32 +#if defined(WIN32) || defined(__APPLE__) // new versions of jack2 are built with HAVE_MIXED_SIZE_ADDRESSING, which induces this error, this is expected if (ret == DB_VERSION_MISMATCH) { + jack_error ("Failed to open previous DB environment, trying again clean..."); + // cleanup old stuff snprintf (dbpath, sizeof(dbpath), "%s/jack_db/metadata.db", fDBFilesDir); remove (dbpath); @@ -145,7 +147,7 @@ int JackMetadata::PropertyInit() if (ret != 0) #endif { - jack_error ("cannot open DB environment: %s", db_strerror (ret)); + jack_error ("Cannot open DB environment: %s", db_strerror (ret)); fDBenv = NULL; return -1; } |