Re: [PATCH] Fix alter subscription concurrency errors - Mailing list pgsql-hackers

From Asif Rehman
Subject Re: [PATCH] Fix alter subscription concurrency errors
Date
Msg-id 166194179843.1087.2373013188766430306.pgcf@coridan.postgresql.org
Whole thread Raw
In response to Re: [PATCH] Fix alter subscription concurrency errors  (Jelte Fennema <Jelte.Fennema@microsoft.com>)
List pgsql-hackers
The following review has been posted through the commitfest application:
make installcheck-world:  tested, passed
Implements feature:       tested, passed
Spec compliant:           not tested
Documentation:            not tested

The patch applies with few "Hunk succeeded, offset -3 lines" warnings. Tested against master '7d5852ca'.

+               if (!HeapTupleIsValid(tup))
+               {
+                       if (!missing_ok)
+                               ereport(ERROR,
+                                               (errcode(ERRCODE_UNDEFINED_OBJECT),
+                                                errmsg("subscription \"%s\" does not exist",
+                                                               subname)));
+                       else
+                               ereport(NOTICE,
+                                               (errmsg("subscription \"%s\" does not exist, skipping",
+                                                               subname)));
+
+                       return InvalidOid;
+               }
+

I think 'tup' should be released before returning, or break out of loop instead to release it.

The new status of this patch is: Waiting on Author

pgsql-hackers by date:

Previous
From: Christoph Berg
Date:
Subject: Re: plpgsql-trigger.html: Format TG_ variables as table (patch)
Next
From: Amit Kapila
Date:
Subject: Re: Handle infinite recursion in logical replication setup