[postgis-tickets] [SCM] PostGIS branch master updated. 3.3.0rc2-575-g7dc3d5e7a

git at osgeo.org git at osgeo.org
Mon Jan 30 08:57:42 PST 2023


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "PostGIS".

The branch, master has been updated
       via  7dc3d5e7ac146f39ff79a0bad44cb51d8983c2a4 (commit)
      from  33e4ee1e92d9b48e169a53d2da34a851117e0363 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 7dc3d5e7ac146f39ff79a0bad44cb51d8983c2a4
Author: Sandro Santilli <strk at kbt.io>
Date:   Mon Jan 30 17:57:07 2023 +0100

    Use scripts_installed for downgrade protection
    
    References #5329 in master branch (3.4.0dev)

diff --git a/utils/create_upgrade.pl b/utils/create_upgrade.pl
index 5d5cc6e88..d6c5225d0 100755
--- a/utils/create_upgrade.pl
+++ b/utils/create_upgrade.pl
@@ -791,25 +791,9 @@ DECLARE
     postgis_upgrade_info RECORD;
     postgis_upgrade_info_func_code TEXT;
 BEGIN
-    --
-    -- This uses postgis_lib_version() rather then
-    -- MODULE_scripts_installed() as in 1.0 because
-    -- in the 1.0 => 1.1 transition that would result
-    -- in an impossible upgrade:
-    --
-    --   from 0.3.0 to 1.1.0
-    --
-    -- Next releases will still be ok as
-    -- postgis_lib_version() and MODULE_scripts_installed()
-    -- would both return actual PostGIS release number.
-    --
-    BEGIN
-        SELECT into old_scripts MODULE_lib_version();
-    EXCEPTION WHEN OTHERS THEN
-        RAISE DEBUG 'Got %', SQLERRM;
-        SELECT into old_scripts MODULE_scripts_installed();
-    END;
-    SELECT into new_scripts 'NEWVERSION';
+
+    old_scripts := MODULE_scripts_installed();
+    new_scripts := 'NEWVERSION';
 
     BEGIN
         new_ver_int := pg_catalog.string_to_array(

-----------------------------------------------------------------------

Summary of changes:
 utils/create_upgrade.pl | 22 +++-------------------
 1 file changed, 3 insertions(+), 19 deletions(-)


hooks/post-receive
-- 
PostGIS


More information about the postgis-tickets mailing list