psycstore: postgres: remove size modifier from BYTEA fields
authorDaniel Golle <daniel@makrotopia.org>
Wed, 12 Oct 2016 23:12:56 +0000 (23:12 +0000)
committerDaniel Golle <daniel@makrotopia.org>
Wed, 12 Oct 2016 23:12:56 +0000 (23:12 +0000)
ERROR:  type modifier is not allowed for type "bytea"

src/psycstore/plugin_psycstore_postgres.c

index 3439856b9434a2bbac2957bdf0ae21c2606aaac1..9240d33348a9504bb3be20f133b3c96eac595fae 100644 (file)
@@ -100,7 +100,7 @@ database_setup (struct Plugin *plugin)
          GNUNET_POSTGRES_exec(plugin->dbh,
                               "CREATE TABLE IF NOT EXISTS channels (\n"
                               " id SERIAL,\n"
-                              " pub_key BYTEA(32),\n"
+                              " pub_key BYTEA,\n"
                               " max_state_message_id BIGINT,\n"
                               " state_hash_message_id BIGINT,\n"
                               " PRIMARY KEY(id)\n"
@@ -121,7 +121,7 @@ database_setup (struct Plugin *plugin)
          GNUNET_POSTGRES_exec(plugin->dbh,
                               "CREATE TABLE IF NOT EXISTS slaves (\n"
                               " id SERIAL,\n"
-                              " pub_key BYTEA(32),\n"
+                              " pub_key BYTEA,\n"
                               " PRIMARY KEY(id)\n"
                               ")" "WITH OIDS")) ||