aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKeith Whyte <keith@rhizomatica.org>2022-06-18 02:51:51 +0100
committerlaforge <laforge@osmocom.org>2022-06-30 20:44:28 +0000
commitea62986928c7052b9af10cec00aeba17dbf85a3a (patch)
treeffe12d3ffc56a2fedb1855e5f7645e06ce0d1f0e
parent5b06a8d6a50036a938d0649ed93617f29531ec25 (diff)
Don't let this osmo-msc operate on a libdbi database
The Binary format changed when libdbi was removed. If we let osmo-msc run on an unconverted database, the results are unpredictable, certainly undesirable. Change-Id: I887b6a4374b1c83684f4007e9791ae58bba4e8c1
-rw-r--r--src/libmsc/db.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/libmsc/db.c b/src/libmsc/db.c
index 07081d54f..0237716e4 100644
--- a/src/libmsc/db.c
+++ b/src/libmsc/db.c
@@ -72,7 +72,7 @@ static struct db_context *g_dbc;
* DATABASE SCHEMA AND MIGRATION
***********************************************************************/
-#define SCHEMA_REVISION "5"
+#define SCHEMA_REVISION "6"
enum {
SCHEMA_META,
@@ -480,14 +480,14 @@ static int check_db_revision(struct db_context *dbc)
LOGP(DDB, LOGL_FATAL, "You must use osmo-msc 1.1.0 to 1.8.0 to upgrade database "
"schema from '%u' to '5', sorry\n", db_rev);
break;
-#if 0
case 5:
- if (update_db_revision_5())
- goto error;
-
- /* The end of waterfall */
+ LOGP(DDB, LOGL_FATAL, "The storage format of BINARY data in the database "
+ "has changed. In order to deliver any pending SMS in your database, "
+ "you must manually convert your database from "
+ "'%u' to '6'. Alternatively you can use a fresh, blank database "
+ "with this version of osmo-msc, sorry.\n", db_rev);
+ return -1;
break;
-#endif
default:
LOGP(DDB, LOGL_FATAL, "Invalid database schema revision '%d'.\n", db_rev);
return -EINVAL;